@squidcloud/client 1.0.147 → 1.0.149
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 +8793 -8803
- package/dist/common/src/ai-assistant.types.d.ts +25 -25
- package/dist/common/src/ai-chatbot.context.d.ts +12 -12
- package/dist/common/src/ai-chatbot.schemas.d.ts +1 -1
- package/dist/common/src/ai-chatbot.types.d.ts +27 -27
- package/dist/common/src/api-call.context.d.ts +13 -13
- package/dist/common/src/api.types.d.ts +4 -4
- package/dist/common/src/application.schemas.d.ts +66 -66
- package/dist/common/src/application.types.d.ts +141 -143
- package/dist/common/src/backend-function.schemas.d.ts +1 -1
- package/dist/common/src/backend-function.types.d.ts +1 -1
- package/dist/common/src/backend-run.types.d.ts +2 -2
- package/dist/common/src/bundle-api.types.d.ts +41 -43
- package/dist/common/src/bundle-data.types.d.ts +5 -5
- package/dist/common/src/communication.types.d.ts +10 -8
- package/dist/common/src/context.types.d.ts +40 -40
- package/dist/common/src/distributed-lock.context.d.ts +4 -4
- package/dist/common/src/document.types.d.ts +22 -22
- package/dist/common/src/graphql.context.d.ts +7 -7
- package/dist/common/src/graphql.types.d.ts +9 -9
- package/dist/common/src/heartbeat.types.d.ts +1 -1
- package/dist/common/src/http-status.enum.d.ts +50 -50
- package/dist/common/src/index.d.ts +54 -57
- package/dist/common/src/integrations/ai_chatbot.types.d.ts +31 -31
- package/dist/common/src/integrations/api.types.d.ts +80 -80
- package/dist/common/src/integrations/auth.types.d.ts +47 -47
- package/dist/common/src/integrations/database.types.d.ts +274 -274
- package/dist/common/src/integrations/index.d.ts +134 -134
- package/dist/common/src/integrations/observability.types.d.ts +23 -23
- package/dist/common/src/logger.types.d.ts +21 -21
- package/dist/common/src/metrics.types.d.ts +1 -1
- package/dist/common/src/mutation.context.d.ts +14 -14
- package/dist/common/src/mutation.schemas.d.ts +1 -1
- package/dist/common/src/mutation.types.d.ts +53 -53
- package/dist/common/src/native-query.context.d.ts +7 -7
- package/dist/common/src/native-query.types.d.ts +16 -16
- package/dist/common/src/query/base-query-builder.d.ts +147 -147
- package/dist/common/src/query/index.d.ts +4 -4
- package/dist/common/src/query/pagination.d.ts +62 -62
- package/dist/common/src/query/query-context.d.ts +137 -137
- package/dist/common/src/query/serialized-query.types.d.ts +24 -24
- package/dist/common/src/query.types.d.ts +64 -64
- package/dist/common/src/regions.d.ts +1 -1
- package/dist/common/src/schema/schema.types.d.ts +54 -54
- package/dist/common/src/secret.schemas.d.ts +1 -1
- package/dist/common/src/secret.types.d.ts +22 -22
- package/dist/common/src/security.types.d.ts +1 -1
- package/dist/common/src/socket.schemas.d.ts +1 -1
- package/dist/common/src/socket.types.d.ts +5 -5
- package/dist/common/src/time-units.d.ts +1 -1
- package/dist/common/src/trigger.types.d.ts +1 -1
- package/dist/common/src/types.d.ts +14 -14
- package/dist/common/src/utils/array.d.ts +1 -1
- package/dist/common/src/utils/assert.d.ts +1 -1
- package/dist/common/src/utils/error.d.ts +4 -4
- package/dist/common/src/utils/global.utils.d.ts +1 -1
- package/dist/common/src/utils/http.d.ts +2 -2
- package/dist/common/src/utils/id.d.ts +2 -2
- package/dist/common/src/utils/lock.manager.d.ts +14 -14
- package/dist/common/src/utils/object.d.ts +5 -5
- package/dist/common/src/utils/serialization.d.ts +5 -6
- package/dist/common/src/utils/transforms.d.ts +18 -18
- package/dist/common/src/utils/url.d.ts +1 -1
- package/dist/common/src/utils/validation.d.ts +25 -25
- package/dist/common/src/webhook-response.d.ts +1 -1
- package/dist/common/src/websocket.impl.d.ts +21 -21
- package/dist/node_modules/json-schema-typed/draft-2020-12.d.ts +1239 -1239
- package/dist/typescript-client/src/ai-assistant-client.d.ts +73 -73
- package/dist/typescript-client/src/ai-chatbot-client.d.ts +174 -174
- package/dist/typescript-client/src/ai-chatbot-client.factory.d.ts +8 -8
- package/dist/typescript-client/src/ai.types.d.ts +61 -61
- package/dist/typescript-client/src/api.manager.d.ts +11 -11
- package/dist/typescript-client/src/auth.manager.d.ts +26 -26
- package/dist/typescript-client/src/backend-function.manager.d.ts +9 -9
- package/dist/typescript-client/src/client-id.service.d.ts +27 -27
- package/dist/typescript-client/src/collection-reference.d.ts +80 -80
- package/dist/typescript-client/src/collection-reference.factory.d.ts +13 -13
- package/dist/typescript-client/src/connection-details.d.ts +23 -23
- package/dist/typescript-client/src/data.manager.d.ts +174 -173
- package/dist/typescript-client/src/destruct.manager.d.ts +12 -12
- package/dist/typescript-client/src/distributed-lock.manager.d.ts +16 -16
- package/dist/typescript-client/src/document-identity.service.d.ts +12 -12
- package/dist/typescript-client/src/document-reference.d.ts +140 -140
- package/dist/typescript-client/src/document-reference.factory.d.ts +13 -13
- package/dist/typescript-client/src/document-store.d.ts +14 -14
- package/dist/typescript-client/src/graphql-client.d.ts +14 -14
- package/dist/typescript-client/src/graphql-client.factory.d.ts +11 -11
- package/dist/typescript-client/src/index.d.ts +9 -9
- package/dist/typescript-client/src/mutation/mutation-sender.d.ts +10 -10
- package/dist/typescript-client/src/native-query-manager.d.ts +7 -7
- package/dist/typescript-client/src/query/deserializer.d.ts +3 -3
- package/dist/typescript-client/src/query/join-query-builder.factory.d.ts +161 -161
- package/dist/typescript-client/src/query/local-query-manager.d.ts +9 -9
- package/dist/typescript-client/src/query/query-builder.factory.d.ts +77 -77
- package/dist/typescript-client/src/query/query-sender.d.ts +33 -33
- package/dist/typescript-client/src/query/query-subscription.manager.d.ts +131 -130
- package/dist/typescript-client/src/query/query.types.d.ts +49 -49
- package/dist/typescript-client/src/rate-limiter.d.ts +32 -32
- package/dist/typescript-client/src/rpc.manager.d.ts +30 -30
- package/dist/typescript-client/src/secret.client.d.ts +22 -22
- package/dist/typescript-client/src/socket.manager.d.ts +43 -43
- package/dist/typescript-client/src/squid.d.ts +238 -269
- package/dist/typescript-client/src/state/state.service.spec.d.ts +1 -1
- package/dist/typescript-client/src/testing/setup-tests.d.ts +1 -1
- package/dist/typescript-client/src/types.d.ts +2 -2
- package/package.json +3 -2
- package/dist/common/src/named-query.context.d.ts +0 -4
- package/dist/common/src/named-query.schemas.d.ts +0 -1
- package/dist/common/src/named-query.types.d.ts +0 -1
- package/dist/typescript-client/src/named-query.manager.d.ts +0 -11
|
@@ -1,43 +1,41 @@
|
|
|
1
|
-
import { AiChatbotActionType, DatabaseActionType } from './bundle-data.types';
|
|
2
|
-
import { DocumentData, SquidDocId } from './document.types';
|
|
3
|
-
import { MutationContext } from './mutation.context';
|
|
4
|
-
import { MutationType } from './mutation.types';
|
|
5
|
-
import { QueryContext } from './query';
|
|
6
|
-
import { ApiCallContext } from './api-call.context';
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
|
|
14
|
-
export type
|
|
15
|
-
export type
|
|
16
|
-
export type
|
|
17
|
-
export type
|
|
18
|
-
export type
|
|
19
|
-
export type
|
|
20
|
-
export type
|
|
21
|
-
export type
|
|
22
|
-
export type
|
|
23
|
-
|
|
24
|
-
export
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
export
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
}
|
|
43
|
-
export type ActionMethodDecorator<U> = <T extends U>(target: Object, propertyName: string, descriptor: TypedPropertyDescriptor<T>) => TypedPropertyDescriptor<T>;
|
|
1
|
+
import { AiChatbotActionType, DatabaseActionType } from './bundle-data.types';
|
|
2
|
+
import { DocumentData, SquidDocId } from './document.types';
|
|
3
|
+
import { MutationContext } from './mutation.context';
|
|
4
|
+
import { MutationType } from './mutation.types';
|
|
5
|
+
import { QueryContext } from './query';
|
|
6
|
+
import { ApiCallContext } from './api-call.context';
|
|
7
|
+
import { GraphqlContext } from './graphql.context';
|
|
8
|
+
import { DistributedLockContext } from './distributed-lock.context';
|
|
9
|
+
import { ClientId } from './communication.types';
|
|
10
|
+
import { ClientConnectionState } from './socket.types';
|
|
11
|
+
import { NativeQueryContext } from './native-query.context';
|
|
12
|
+
import { AiChatbotChatContext, AiChatbotMutationContext } from './ai-chatbot.context';
|
|
13
|
+
export type SecureDatabaseAction<T extends DatabaseActionType> = T extends 'all' ? () => boolean | Promise<boolean> : T extends 'read' ? ((context: QueryContext) => boolean | Promise<boolean>) | (() => boolean | Promise<boolean>) : ((context: MutationContext) => boolean | Promise<boolean>) | (() => boolean | Promise<boolean>);
|
|
14
|
+
export type SecureApiAction = ((context: ApiCallContext) => boolean | Promise<boolean>) | (() => boolean | Promise<boolean>);
|
|
15
|
+
export type SecureNativeQueryAction = ((context: NativeQueryContext) => boolean | Promise<boolean>) | (() => boolean | Promise<boolean>);
|
|
16
|
+
export type SecureDistributedLockAction = ((context: DistributedLockContext) => boolean | Promise<boolean>) | (() => boolean | Promise<boolean>);
|
|
17
|
+
export type SecureGraphQLAction = ((context: GraphqlContext) => boolean | Promise<boolean>) | (() => boolean | Promise<boolean>);
|
|
18
|
+
export type SecureAiChatbotAction<T extends AiChatbotActionType> = T extends 'all' ? () => boolean | Promise<boolean> : T extends 'chat' ? ((context: AiChatbotChatContext) => boolean | Promise<boolean>) | (() => boolean | Promise<boolean>) : ((context: AiChatbotMutationContext) => boolean | Promise<boolean>) | (() => boolean | Promise<boolean>);
|
|
19
|
+
export type ClientConnectionStateChangeAction = (clientId: ClientId, clientConnectionState: ClientConnectionState) => Promise<void> | void;
|
|
20
|
+
export type ExecutableAction = (...args: any[]) => any;
|
|
21
|
+
export type AiFunctionAction<T extends Record<string, any> = any> = (params: T) => any;
|
|
22
|
+
export type TriggerAction = ((request: TriggerRequest) => void | Promise<void>) | (() => void | Promise<void>);
|
|
23
|
+
/** The context provided to a trigger function. */
|
|
24
|
+
export interface TriggerRequest<T extends DocumentData = any> {
|
|
25
|
+
squidDocId: SquidDocId;
|
|
26
|
+
mutationType: MutationType;
|
|
27
|
+
docBefore?: T;
|
|
28
|
+
docAfter?: T;
|
|
29
|
+
}
|
|
30
|
+
export type SchedulerAction = () => void | Promise<void>;
|
|
31
|
+
export type WebhookAction = ((request: WebhookRequest) => any) | (() => any);
|
|
32
|
+
/** The context provided to a webhook function. */
|
|
33
|
+
export interface WebhookRequest {
|
|
34
|
+
body: any;
|
|
35
|
+
rawBody?: string;
|
|
36
|
+
queryParams: Record<string, string>;
|
|
37
|
+
headers: Record<string, string>;
|
|
38
|
+
httpMethod: 'post' | 'get' | 'put' | 'delete';
|
|
39
|
+
files?: Array<SquidFile>;
|
|
40
|
+
}
|
|
41
|
+
export type ActionMethodDecorator<U> = <T extends U>(target: Object, propertyName: string, descriptor: TypedPropertyDescriptor<T>) => TypedPropertyDescriptor<T>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
/** The different types of actions that can be performed on a database. */
|
|
2
|
-
export type DatabaseActionType = 'read' | 'write' | 'update' | 'insert' | 'delete' | 'all';
|
|
3
|
-
/** The different types of actions that can be performed on an AI chatbot. */
|
|
4
|
-
export type AiChatbotActionType = 'chat' | 'mutate' | 'all';
|
|
5
|
-
export type AiFunctionParamType = 'string' | 'number' | 'boolean' | 'date';
|
|
1
|
+
/** The different types of actions that can be performed on a database. */
|
|
2
|
+
export type DatabaseActionType = 'read' | 'write' | 'update' | 'insert' | 'delete' | 'all';
|
|
3
|
+
/** The different types of actions that can be performed on an AI chatbot. */
|
|
4
|
+
export type AiChatbotActionType = 'chat' | 'mutate' | 'all';
|
|
5
|
+
export type AiFunctionParamType = 'string' | 'number' | 'boolean' | 'date';
|
|
@@ -1,8 +1,10 @@
|
|
|
1
|
-
/** A type alias for an application id. */
|
|
2
|
-
export type AppId = string;
|
|
3
|
-
export
|
|
4
|
-
export
|
|
5
|
-
/**
|
|
6
|
-
export
|
|
7
|
-
|
|
8
|
-
export type
|
|
1
|
+
/** A type alias for an application id. */
|
|
2
|
+
export type AppId = string;
|
|
3
|
+
export declare const ENVIRONMENT_IDS: readonly ["dev", "prod"];
|
|
4
|
+
export type EnvironmentId = (typeof ENVIRONMENT_IDS)[number];
|
|
5
|
+
/** @deprecated. Use ENVIRONMENT_IDS. */
|
|
6
|
+
export declare const allEnvironmentIds: Array<EnvironmentId>;
|
|
7
|
+
/** A type alias for an integration id. */
|
|
8
|
+
export type IntegrationId = string;
|
|
9
|
+
export type ChatId = string;
|
|
10
|
+
export type SquidDeveloperId = string;
|
|
@@ -1,40 +1,40 @@
|
|
|
1
|
-
import { AppId, ClientId } from './communication.types';
|
|
2
|
-
export type AuthType = 'Bearer' | 'ApiKey';
|
|
3
|
-
/**
|
|
4
|
-
* The payload of a JWT token in case an auth token was used.
|
|
5
|
-
*/
|
|
6
|
-
export interface AuthWithBearer {
|
|
7
|
-
type: 'Bearer';
|
|
8
|
-
userId: string;
|
|
9
|
-
expiration: number;
|
|
10
|
-
attributes: Record<string, any>;
|
|
11
|
-
}
|
|
12
|
-
/**
|
|
13
|
-
* The authentication object for the current request in case an API key is used.
|
|
14
|
-
*/
|
|
15
|
-
export interface AuthWithApiKey {
|
|
16
|
-
type: 'ApiKey';
|
|
17
|
-
apiKey: string;
|
|
18
|
-
}
|
|
19
|
-
/** The authentication object for the current request. */
|
|
20
|
-
export type Auth = AuthWithBearer | AuthWithApiKey;
|
|
21
|
-
export interface AuthToken {
|
|
22
|
-
type: AuthType;
|
|
23
|
-
token: string;
|
|
24
|
-
integrationId?: string;
|
|
25
|
-
}
|
|
26
|
-
/** The context of a request to a service. */
|
|
27
|
-
export interface RunContext {
|
|
28
|
-
/** Your applicationId. */
|
|
29
|
-
appId: AppId;
|
|
30
|
-
/**
|
|
31
|
-
* The id of the client that initiated this request. This is only relevant in cases that the request was initiated by
|
|
32
|
-
* a client such as when securing an api call or a DB operation. This id will not be available for triggers,
|
|
33
|
-
* schedulers, webhooks and other functions that are not directly initiated by a user action.
|
|
34
|
-
*/
|
|
35
|
-
clientId?: ClientId;
|
|
36
|
-
/** The IP address of the client that initiated this request. */
|
|
37
|
-
sourceIp?: string;
|
|
38
|
-
/** The headers of the request. */
|
|
39
|
-
headers?: Record<string, any>;
|
|
40
|
-
}
|
|
1
|
+
import { AppId, ClientId } from './communication.types';
|
|
2
|
+
export type AuthType = 'Bearer' | 'ApiKey';
|
|
3
|
+
/**
|
|
4
|
+
* The payload of a JWT token in case an auth token was used.
|
|
5
|
+
*/
|
|
6
|
+
export interface AuthWithBearer {
|
|
7
|
+
type: 'Bearer';
|
|
8
|
+
userId: string;
|
|
9
|
+
expiration: number;
|
|
10
|
+
attributes: Record<string, any>;
|
|
11
|
+
}
|
|
12
|
+
/**
|
|
13
|
+
* The authentication object for the current request in case an API key is used.
|
|
14
|
+
*/
|
|
15
|
+
export interface AuthWithApiKey {
|
|
16
|
+
type: 'ApiKey';
|
|
17
|
+
apiKey: string;
|
|
18
|
+
}
|
|
19
|
+
/** The authentication object for the current request. */
|
|
20
|
+
export type Auth = AuthWithBearer | AuthWithApiKey;
|
|
21
|
+
export interface AuthToken {
|
|
22
|
+
type: AuthType;
|
|
23
|
+
token: string;
|
|
24
|
+
integrationId?: string;
|
|
25
|
+
}
|
|
26
|
+
/** The context of a request to a service. */
|
|
27
|
+
export interface RunContext {
|
|
28
|
+
/** Your applicationId. */
|
|
29
|
+
appId: AppId;
|
|
30
|
+
/**
|
|
31
|
+
* The id of the client that initiated this request. This is only relevant in cases that the request was initiated by
|
|
32
|
+
* a client such as when securing an api call or a DB operation. This id will not be available for triggers,
|
|
33
|
+
* schedulers, webhooks and other functions that are not directly initiated by a user action.
|
|
34
|
+
*/
|
|
35
|
+
clientId?: ClientId;
|
|
36
|
+
/** The IP address of the client that initiated this request. */
|
|
37
|
+
sourceIp?: string;
|
|
38
|
+
/** The headers of the request. */
|
|
39
|
+
headers?: Record<string, any>;
|
|
40
|
+
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/** The context provided to a secure distributed lock function. */
|
|
2
|
-
export declare class DistributedLockContext {
|
|
3
|
-
readonly mutex: string;
|
|
4
|
-
}
|
|
1
|
+
/** The context provided to a secure distributed lock function. */
|
|
2
|
+
export declare class DistributedLockContext {
|
|
3
|
+
readonly mutex: string;
|
|
4
|
+
}
|
|
@@ -1,22 +1,22 @@
|
|
|
1
|
-
import { IntegrationId } from './communication.types';
|
|
2
|
-
/** A type alias for a field name. */
|
|
3
|
-
export type FieldName<T = any> = string & keyof T;
|
|
4
|
-
/** A type alias for a document id as string. */
|
|
5
|
-
export type DocId = string;
|
|
6
|
-
/** A type alias for a document id object when the ID is a composite of primary keys. */
|
|
7
|
-
export type DocIdObj = Record<FieldName, any>;
|
|
8
|
-
/** A type alias for a collection name. */
|
|
9
|
-
export type CollectionName = string;
|
|
10
|
-
/** The full document id, including the collection name and the integration id. */
|
|
11
|
-
export interface SquidDocIdObj {
|
|
12
|
-
collectionName: CollectionName;
|
|
13
|
-
docId: DocId;
|
|
14
|
-
integrationId: IntegrationId;
|
|
15
|
-
}
|
|
16
|
-
/** The before and after documents of a document change. */
|
|
17
|
-
export interface BeforeAndAfterDocs<T = SquidDocument> {
|
|
18
|
-
before: T | undefined;
|
|
19
|
-
after: T | undefined;
|
|
20
|
-
}
|
|
21
|
-
/** A generic document data type. */
|
|
22
|
-
export type DocumentData = Record<FieldName, any | undefined>;
|
|
1
|
+
import { IntegrationId } from './communication.types';
|
|
2
|
+
/** A type alias for a field name. */
|
|
3
|
+
export type FieldName<T = any> = string & keyof T;
|
|
4
|
+
/** A type alias for a document id as string. */
|
|
5
|
+
export type DocId = string;
|
|
6
|
+
/** A type alias for a document id object when the ID is a composite of primary keys. */
|
|
7
|
+
export type DocIdObj = Record<FieldName, any>;
|
|
8
|
+
/** A type alias for a collection name. */
|
|
9
|
+
export type CollectionName = string;
|
|
10
|
+
/** The full document id, including the collection name and the integration id. */
|
|
11
|
+
export interface SquidDocIdObj {
|
|
12
|
+
collectionName: CollectionName;
|
|
13
|
+
docId: DocId;
|
|
14
|
+
integrationId: IntegrationId;
|
|
15
|
+
}
|
|
16
|
+
/** The before and after documents of a document change. */
|
|
17
|
+
export interface BeforeAndAfterDocs<T = SquidDocument> {
|
|
18
|
+
before: T | undefined;
|
|
19
|
+
after: T | undefined;
|
|
20
|
+
}
|
|
21
|
+
/** A generic document data type. */
|
|
22
|
+
export type DocumentData = Record<FieldName, any | undefined>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
/** The context provided to a secure GraphQL function. */
|
|
2
|
-
export declare class GraphqlContext {
|
|
3
|
-
readonly isGraphiQL: boolean;
|
|
4
|
-
readonly query: string | undefined;
|
|
5
|
-
readonly variables: string | Record<string, any> | undefined;
|
|
6
|
-
readonly operationName: string | undefined;
|
|
7
|
-
}
|
|
1
|
+
/** The context provided to a secure GraphQL function. */
|
|
2
|
+
export declare class GraphqlContext {
|
|
3
|
+
readonly isGraphiQL: boolean;
|
|
4
|
+
readonly query: string | undefined;
|
|
5
|
+
readonly variables: string | Record<string, any> | undefined;
|
|
6
|
+
readonly operationName: string | undefined;
|
|
7
|
+
}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
export { ExecutionResult, IntrospectionQuery } from 'graphql';
|
|
2
|
-
export interface GraphQLRequest {
|
|
3
|
-
operationName?: string;
|
|
4
|
-
query?: string;
|
|
5
|
-
variables?: string | Record<string, any>;
|
|
6
|
-
}
|
|
7
|
-
export interface SecureGraphQLRequest extends GraphQLRequest {
|
|
8
|
-
isGraphiQL: boolean;
|
|
9
|
-
}
|
|
1
|
+
export { ExecutionResult, IntrospectionQuery } from 'graphql';
|
|
2
|
+
export interface GraphQLRequest {
|
|
3
|
+
operationName?: string;
|
|
4
|
+
query?: string;
|
|
5
|
+
variables?: string | Record<string, any>;
|
|
6
|
+
}
|
|
7
|
+
export interface SecureGraphQLRequest extends GraphQLRequest {
|
|
8
|
+
isGraphiQL: boolean;
|
|
9
|
+
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare function checkAllHeartbeatProviders(heartbeatProviders: Record<string, HeartbeatProvider>): Promise<void>;
|
|
1
|
+
export declare function checkAllHeartbeatProviders(heartbeatProviders: Record<string, HeartbeatProvider>): Promise<void>;
|
|
@@ -1,50 +1,50 @@
|
|
|
1
|
-
export declare enum HttpStatus {
|
|
2
|
-
CONTINUE = 100,
|
|
3
|
-
SWITCHING_PROTOCOLS = 101,
|
|
4
|
-
PROCESSING = 102,
|
|
5
|
-
EARLYHINTS = 103,
|
|
6
|
-
OK = 200,
|
|
7
|
-
CREATED = 201,
|
|
8
|
-
ACCEPTED = 202,
|
|
9
|
-
NON_AUTHORITATIVE_INFORMATION = 203,
|
|
10
|
-
NO_CONTENT = 204,
|
|
11
|
-
RESET_CONTENT = 205,
|
|
12
|
-
PARTIAL_CONTENT = 206,
|
|
13
|
-
AMBIGUOUS = 300,
|
|
14
|
-
MOVED_PERMANENTLY = 301,
|
|
15
|
-
FOUND = 302,
|
|
16
|
-
SEE_OTHER = 303,
|
|
17
|
-
NOT_MODIFIED = 304,
|
|
18
|
-
TEMPORARY_REDIRECT = 307,
|
|
19
|
-
PERMANENT_REDIRECT = 308,
|
|
20
|
-
BAD_REQUEST = 400,
|
|
21
|
-
UNAUTHORIZED = 401,
|
|
22
|
-
PAYMENT_REQUIRED = 402,
|
|
23
|
-
FORBIDDEN = 403,
|
|
24
|
-
NOT_FOUND = 404,
|
|
25
|
-
METHOD_NOT_ALLOWED = 405,
|
|
26
|
-
NOT_ACCEPTABLE = 406,
|
|
27
|
-
PROXY_AUTHENTICATION_REQUIRED = 407,
|
|
28
|
-
REQUEST_TIMEOUT = 408,
|
|
29
|
-
CONFLICT = 409,
|
|
30
|
-
GONE = 410,
|
|
31
|
-
LENGTH_REQUIRED = 411,
|
|
32
|
-
PRECONDITION_FAILED = 412,
|
|
33
|
-
PAYLOAD_TOO_LARGE = 413,
|
|
34
|
-
URI_TOO_LONG = 414,
|
|
35
|
-
UNSUPPORTED_MEDIA_TYPE = 415,
|
|
36
|
-
REQUESTED_RANGE_NOT_SATISFIABLE = 416,
|
|
37
|
-
EXPECTATION_FAILED = 417,
|
|
38
|
-
I_AM_A_TEAPOT = 418,
|
|
39
|
-
MISDIRECTED = 421,
|
|
40
|
-
UNPROCESSABLE_ENTITY = 422,
|
|
41
|
-
FAILED_DEPENDENCY = 424,
|
|
42
|
-
PRECONDITION_REQUIRED = 428,
|
|
43
|
-
TOO_MANY_REQUESTS = 429,
|
|
44
|
-
INTERNAL_SERVER_ERROR = 500,
|
|
45
|
-
NOT_IMPLEMENTED = 501,
|
|
46
|
-
BAD_GATEWAY = 502,
|
|
47
|
-
SERVICE_UNAVAILABLE = 503,
|
|
48
|
-
GATEWAY_TIMEOUT = 504,
|
|
49
|
-
HTTP_VERSION_NOT_SUPPORTED = 505
|
|
50
|
-
}
|
|
1
|
+
export declare enum HttpStatus {
|
|
2
|
+
CONTINUE = 100,
|
|
3
|
+
SWITCHING_PROTOCOLS = 101,
|
|
4
|
+
PROCESSING = 102,
|
|
5
|
+
EARLYHINTS = 103,
|
|
6
|
+
OK = 200,
|
|
7
|
+
CREATED = 201,
|
|
8
|
+
ACCEPTED = 202,
|
|
9
|
+
NON_AUTHORITATIVE_INFORMATION = 203,
|
|
10
|
+
NO_CONTENT = 204,
|
|
11
|
+
RESET_CONTENT = 205,
|
|
12
|
+
PARTIAL_CONTENT = 206,
|
|
13
|
+
AMBIGUOUS = 300,
|
|
14
|
+
MOVED_PERMANENTLY = 301,
|
|
15
|
+
FOUND = 302,
|
|
16
|
+
SEE_OTHER = 303,
|
|
17
|
+
NOT_MODIFIED = 304,
|
|
18
|
+
TEMPORARY_REDIRECT = 307,
|
|
19
|
+
PERMANENT_REDIRECT = 308,
|
|
20
|
+
BAD_REQUEST = 400,
|
|
21
|
+
UNAUTHORIZED = 401,
|
|
22
|
+
PAYMENT_REQUIRED = 402,
|
|
23
|
+
FORBIDDEN = 403,
|
|
24
|
+
NOT_FOUND = 404,
|
|
25
|
+
METHOD_NOT_ALLOWED = 405,
|
|
26
|
+
NOT_ACCEPTABLE = 406,
|
|
27
|
+
PROXY_AUTHENTICATION_REQUIRED = 407,
|
|
28
|
+
REQUEST_TIMEOUT = 408,
|
|
29
|
+
CONFLICT = 409,
|
|
30
|
+
GONE = 410,
|
|
31
|
+
LENGTH_REQUIRED = 411,
|
|
32
|
+
PRECONDITION_FAILED = 412,
|
|
33
|
+
PAYLOAD_TOO_LARGE = 413,
|
|
34
|
+
URI_TOO_LONG = 414,
|
|
35
|
+
UNSUPPORTED_MEDIA_TYPE = 415,
|
|
36
|
+
REQUESTED_RANGE_NOT_SATISFIABLE = 416,
|
|
37
|
+
EXPECTATION_FAILED = 417,
|
|
38
|
+
I_AM_A_TEAPOT = 418,
|
|
39
|
+
MISDIRECTED = 421,
|
|
40
|
+
UNPROCESSABLE_ENTITY = 422,
|
|
41
|
+
FAILED_DEPENDENCY = 424,
|
|
42
|
+
PRECONDITION_REQUIRED = 428,
|
|
43
|
+
TOO_MANY_REQUESTS = 429,
|
|
44
|
+
INTERNAL_SERVER_ERROR = 500,
|
|
45
|
+
NOT_IMPLEMENTED = 501,
|
|
46
|
+
BAD_GATEWAY = 502,
|
|
47
|
+
SERVICE_UNAVAILABLE = 503,
|
|
48
|
+
GATEWAY_TIMEOUT = 504,
|
|
49
|
+
HTTP_VERSION_NOT_SUPPORTED = 505
|
|
50
|
+
}
|
|
@@ -1,57 +1,54 @@
|
|
|
1
|
-
export * from './ai-chatbot.schemas';
|
|
2
|
-
export * from './ai-chatbot.types';
|
|
3
|
-
export * from './ai-assistant.types';
|
|
4
|
-
export * from './api-call.context';
|
|
5
|
-
export * from './api.types';
|
|
6
|
-
export * from './application.schemas';
|
|
7
|
-
export * from './application.types';
|
|
8
|
-
export * from './backend-function.schemas';
|
|
9
|
-
export * from './backend-function.types';
|
|
10
|
-
export * from './backend-run.types';
|
|
11
|
-
export * from './bundle-api.types';
|
|
12
|
-
export * from './bundle-data.types';
|
|
13
|
-
export * from './communication.types';
|
|
14
|
-
export * from './context.types';
|
|
15
|
-
export * from './distributed-lock.context';
|
|
16
|
-
export * from './document.types';
|
|
17
|
-
export * from './graphql.context';
|
|
18
|
-
export * from './graphql.types';
|
|
19
|
-
export * from './http-status.enum';
|
|
20
|
-
export * from './integrations';
|
|
21
|
-
export * from './logger.types';
|
|
22
|
-
export * from './metrics.types';
|
|
23
|
-
export * from './mutation.context';
|
|
24
|
-
export * from './mutation.schemas';
|
|
25
|
-
export * from './mutation.types';
|
|
26
|
-
export * from './
|
|
27
|
-
export * from './
|
|
28
|
-
export * from './
|
|
29
|
-
export * from './
|
|
30
|
-
export * from './
|
|
31
|
-
export * from './
|
|
32
|
-
export * from './
|
|
33
|
-
export * from './
|
|
34
|
-
export * from './
|
|
35
|
-
export * from './
|
|
36
|
-
export * from './
|
|
37
|
-
export * from './
|
|
38
|
-
export * from './
|
|
39
|
-
export * from './
|
|
40
|
-
export * from './
|
|
41
|
-
export * from './
|
|
42
|
-
export * from './
|
|
43
|
-
export * from './utils/
|
|
44
|
-
export * from './utils/
|
|
45
|
-
export * from './utils/
|
|
46
|
-
export * from './utils/
|
|
47
|
-
export * from './utils/
|
|
48
|
-
export * from './utils/
|
|
49
|
-
export * from './utils/
|
|
50
|
-
export * from './utils/
|
|
51
|
-
export * from './
|
|
52
|
-
export * from './
|
|
53
|
-
export * from './utils/
|
|
54
|
-
export * from './
|
|
55
|
-
export * from './heartbeat.types';
|
|
56
|
-
export * from './utils/global.utils';
|
|
57
|
-
export * from './websocket.impl';
|
|
1
|
+
export * from './ai-chatbot.schemas';
|
|
2
|
+
export * from './ai-chatbot.types';
|
|
3
|
+
export * from './ai-assistant.types';
|
|
4
|
+
export * from './api-call.context';
|
|
5
|
+
export * from './api.types';
|
|
6
|
+
export * from './application.schemas';
|
|
7
|
+
export * from './application.types';
|
|
8
|
+
export * from './backend-function.schemas';
|
|
9
|
+
export * from './backend-function.types';
|
|
10
|
+
export * from './backend-run.types';
|
|
11
|
+
export * from './bundle-api.types';
|
|
12
|
+
export * from './bundle-data.types';
|
|
13
|
+
export * from './communication.types';
|
|
14
|
+
export * from './context.types';
|
|
15
|
+
export * from './distributed-lock.context';
|
|
16
|
+
export * from './document.types';
|
|
17
|
+
export * from './graphql.context';
|
|
18
|
+
export * from './graphql.types';
|
|
19
|
+
export * from './http-status.enum';
|
|
20
|
+
export * from './integrations';
|
|
21
|
+
export * from './logger.types';
|
|
22
|
+
export * from './metrics.types';
|
|
23
|
+
export * from './mutation.context';
|
|
24
|
+
export * from './mutation.schemas';
|
|
25
|
+
export * from './mutation.types';
|
|
26
|
+
export * from './native-query.context';
|
|
27
|
+
export * from './native-query.types';
|
|
28
|
+
export * from './query';
|
|
29
|
+
export * from './query.types';
|
|
30
|
+
export * from './regions';
|
|
31
|
+
export * from './schema/schema.types';
|
|
32
|
+
export * from './secret.schemas';
|
|
33
|
+
export * from './secret.types';
|
|
34
|
+
export * from './security.types';
|
|
35
|
+
export * from './socket.schemas';
|
|
36
|
+
export * from './socket.types';
|
|
37
|
+
export * from './time-units';
|
|
38
|
+
export * from './trigger.types';
|
|
39
|
+
export * from './types';
|
|
40
|
+
export * from './utils/array';
|
|
41
|
+
export * from './utils/assert';
|
|
42
|
+
export * from './utils/error';
|
|
43
|
+
export * from './utils/http';
|
|
44
|
+
export * from './utils/id';
|
|
45
|
+
export * from './utils/lock.manager';
|
|
46
|
+
export * from './utils/object';
|
|
47
|
+
export * from './utils/serialization';
|
|
48
|
+
export * from './utils/transforms';
|
|
49
|
+
export * from './utils/url';
|
|
50
|
+
export * from './utils/validation';
|
|
51
|
+
export * from './webhook-response';
|
|
52
|
+
export * from './heartbeat.types';
|
|
53
|
+
export * from './utils/global.utils';
|
|
54
|
+
export * from './websocket.impl';
|
|
@@ -1,31 +1,31 @@
|
|
|
1
|
-
import { AiModelName } from '../ai-chatbot.types';
|
|
2
|
-
import { IntegrationId } from '../communication.types';
|
|
3
|
-
import { BaseIntegrationConfig, IntegrationType } from './index';
|
|
4
|
-
export interface AiChatbotIntegrationConfig extends BaseIntegrationConfig {
|
|
5
|
-
type: IntegrationType.ai_chatbot;
|
|
6
|
-
configuration: AiChatbotConfiguration;
|
|
7
|
-
}
|
|
8
|
-
export type AiChatbotConfiguration = {
|
|
9
|
-
apiKey?: string;
|
|
10
|
-
};
|
|
11
|
-
export type AiChatbotProfileMetadata = {
|
|
12
|
-
modelName: AiModelName;
|
|
13
|
-
isPublic: boolean;
|
|
14
|
-
strictContext: boolean;
|
|
15
|
-
instructions: Record<string, string>;
|
|
16
|
-
};
|
|
17
|
-
export type AiChatbotContextMetadata = {
|
|
18
|
-
title: string;
|
|
19
|
-
text: string;
|
|
20
|
-
preview: boolean;
|
|
21
|
-
sizeBytes?: number;
|
|
22
|
-
};
|
|
23
|
-
export interface AiChatbotProfile extends AiChatbotProfileMetadata {
|
|
24
|
-
contexts: Record<string, AiChatbotContextMetadata>;
|
|
25
|
-
}
|
|
26
|
-
export interface AiChatbotProfiles {
|
|
27
|
-
profiles: Record<string, AiChatbotProfile>;
|
|
28
|
-
}
|
|
29
|
-
export interface GetAiChatbotProfilesRequest {
|
|
30
|
-
integrationId: IntegrationId;
|
|
31
|
-
}
|
|
1
|
+
import { AiModelName } from '../ai-chatbot.types';
|
|
2
|
+
import { IntegrationId } from '../communication.types';
|
|
3
|
+
import { BaseIntegrationConfig, IntegrationType } from './index';
|
|
4
|
+
export interface AiChatbotIntegrationConfig extends BaseIntegrationConfig {
|
|
5
|
+
type: IntegrationType.ai_chatbot;
|
|
6
|
+
configuration: AiChatbotConfiguration;
|
|
7
|
+
}
|
|
8
|
+
export type AiChatbotConfiguration = {
|
|
9
|
+
apiKey?: string;
|
|
10
|
+
};
|
|
11
|
+
export type AiChatbotProfileMetadata = {
|
|
12
|
+
modelName: AiModelName;
|
|
13
|
+
isPublic: boolean;
|
|
14
|
+
strictContext: boolean;
|
|
15
|
+
instructions: Record<string, string>;
|
|
16
|
+
};
|
|
17
|
+
export type AiChatbotContextMetadata = {
|
|
18
|
+
title: string;
|
|
19
|
+
text: string;
|
|
20
|
+
preview: boolean;
|
|
21
|
+
sizeBytes?: number;
|
|
22
|
+
};
|
|
23
|
+
export interface AiChatbotProfile extends AiChatbotProfileMetadata {
|
|
24
|
+
contexts: Record<string, AiChatbotContextMetadata>;
|
|
25
|
+
}
|
|
26
|
+
export interface AiChatbotProfiles {
|
|
27
|
+
profiles: Record<string, AiChatbotProfile>;
|
|
28
|
+
}
|
|
29
|
+
export interface GetAiChatbotProfilesRequest {
|
|
30
|
+
integrationId: IntegrationId;
|
|
31
|
+
}
|