@squidcloud/client 1.0.172 → 1.0.174

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.
Files changed (33) hide show
  1. package/dist/cjs/index.js +3840 -3808
  2. package/dist/internal-common/src/public-types/ai-assistant.public-types.d.ts +0 -24
  3. package/dist/internal-common/src/public-types/ai-chatbot.public-context.d.ts +2 -0
  4. package/dist/internal-common/src/public-types/ai-chatbot.public-types.d.ts +1 -16
  5. package/dist/internal-common/src/public-types/api-call.public-context.d.ts +1 -1
  6. package/dist/internal-common/src/public-types/application.public-types.d.ts +0 -37
  7. package/dist/internal-common/src/public-types/integrations/ai_chatbot.public-types.d.ts +31 -0
  8. package/dist/internal-common/src/public-types/integrations/api.public-types.d.ts +41 -0
  9. package/dist/internal-common/src/public-types/pagination.public-types.d.ts +1 -1
  10. package/dist/internal-common/src/public-types/query.public-types.d.ts +1 -0
  11. package/dist/internal-common/src/public-types/secret.public-types.d.ts +8 -0
  12. package/dist/internal-common/src/types/api.types.d.ts +1 -2
  13. package/dist/internal-common/src/types/integrations/ai_chatbot.types.d.ts +1 -0
  14. package/dist/internal-common/src/types/integrations/api.types.d.ts +1 -0
  15. package/dist/internal-common/src/types/integrations/auth.types.d.ts +1 -0
  16. package/dist/internal-common/src/types/integrations/database.types.d.ts +1 -0
  17. package/dist/internal-common/src/types/integrations/observability.types.d.ts +1 -0
  18. package/dist/internal-common/src/types/integrations/queue-types.d.ts +1 -0
  19. package/dist/internal-common/src/types/integrations/schemas.d.ts +1 -0
  20. package/dist/internal-common/src/types/secret.types.d.ts +0 -9
  21. package/dist/internal-common/src/utils/object.d.ts +1 -1
  22. package/dist/internal-common/src/utils/squid-private-options.d.ts +15 -0
  23. package/dist/typescript-client/src/index.d.ts +5 -4
  24. package/dist/typescript-client/src/public-types.d.ts +2 -7
  25. package/dist/typescript-client/src/secret.client.d.ts +1 -2
  26. package/package.json +2 -2
  27. package/dist/internal-common/src/public-types/integrations/ai_chatbot.types.d.ts +0 -32
  28. package/dist/internal-common/src/public-types/integrations/api.types.d.ts +0 -81
  29. package/dist/internal-common/src/public-types/integrations/auth.types.d.ts +0 -54
  30. package/dist/internal-common/src/public-types/integrations/database.types.d.ts +0 -228
  31. package/dist/internal-common/src/public-types/integrations/observability.types.d.ts +0 -24
  32. package/dist/internal-common/src/public-types/integrations/queue-types.d.ts +0 -40
  33. package/dist/internal-common/src/public-types/integrations/schemas.d.ts +0 -72
@@ -1,25 +1 @@
1
- import { FunctionName } from './bundle-data.public-types';
2
1
  export type AssistantToolType = 'code_interpreter' | 'retrieval';
3
- export interface CreateAssistantRequest {
4
- name: string;
5
- instructions: string;
6
- functions: Array<FunctionName>;
7
- toolTypes?: Array<AssistantToolType>;
8
- }
9
- export interface DeleteAssistantRequest {
10
- assistantId: string;
11
- }
12
- export interface CreateAssistantThreadRequest {
13
- assistantId: string;
14
- }
15
- export interface DeleteThreadRequest {
16
- threadId: string;
17
- }
18
- export interface CreateAssistantThreadRequest {
19
- }
20
- export interface CreateAssistantResponse {
21
- assistantId: string;
22
- }
23
- export interface CreateAssistantThreadResponse {
24
- threadId: string;
25
- }
@@ -1,4 +1,5 @@
1
1
  import { AiChatbotMutationType, AiChatbotResourceType } from './ai-chatbot.public-types';
2
+ import { AiChatbotFileContext, AiChatbotTextContext, AiChatbotUrlContext } from './integrations/ai_chatbot.public-types';
2
3
  export declare class AiChatbotChatContext {
3
4
  readonly prompt: string;
4
5
  readonly profileId: string;
@@ -10,3 +11,4 @@ export declare class AiChatbotMutationContext {
10
11
  readonly profileId: string;
11
12
  readonly payload: any;
12
13
  }
14
+ export type AiChatbotContext = AiChatbotTextContext | AiChatbotUrlContext | AiChatbotFileContext;
@@ -3,21 +3,6 @@ export declare const AI_MODEL_NAMES: readonly ["gpt-3.5-turbo", "gpt-3.5-turbo-1
3
3
  export type AiModelName = (typeof AI_MODEL_NAMES)[number];
4
4
  /** The possible sources for the LLM provider API key. */
5
5
  export type ApiKeySource = 'user' | 'system';
6
- export type AiChatbotContextType = 'text' | 'url' | 'file';
7
- interface AiChatbotContextBase {
8
- type: AiChatbotContextType;
9
- data: string;
10
- }
11
- export interface AiChatbotTextContext extends AiChatbotContextBase {
12
- type: 'text';
13
- }
14
- export interface AiChatbotUrlContext extends AiChatbotContextBase {
15
- type: 'url';
16
- }
17
- export interface AiChatbotFileContext extends AiChatbotContextBase {
18
- type: 'file';
19
- }
20
- export type AiChatbotContext = AiChatbotTextContext | AiChatbotUrlContext | AiChatbotFileContext;
21
6
  export type OpenAiResponseFormat = 'text' | 'json_object';
22
7
  export interface AiChatbotChatOptions {
23
8
  maxTokens?: number;
@@ -25,7 +10,7 @@ export interface AiChatbotChatOptions {
25
10
  disableHistory?: boolean;
26
11
  includeReference?: boolean;
27
12
  responseFormat?: OpenAiResponseFormat;
13
+ smoothTyping?: boolean;
28
14
  }
29
15
  export type AiChatbotMutationType = 'insert' | 'update' | 'delete';
30
16
  export type AiChatbotResourceType = 'instruction' | 'context' | 'profile';
31
- export {};
@@ -1,4 +1,4 @@
1
- import { ApiEndpointId, HttpMethod } from './integrations/api.types';
1
+ import { ApiEndpointId, HttpMethod } from './integrations/api.public-types';
2
2
  /** The headers of an API call. */
3
3
  export type ApiHeaders = Record<string, string | number | boolean>;
4
4
  /** The context of an API call. */
@@ -1,6 +1,3 @@
1
- import { AuthIntegrationType, DatabaseIntegrationType, IntegrationConfig, IntegrationConfigTypes, IntegrationSchema, IntegrationSchemaKeys, IntegrationSchemaTypes, IntegrationTypeWithConfig } from './integrations/schemas';
2
- import { IntegrationType } from './integration.public-types';
3
- import { IntegrationId } from './communication.public-types';
4
1
  /** A type alias for a string that represents a webhook. */
5
2
  export type WebhookId = string;
6
3
  /** A type alias for a string that represents a trigger id. */
@@ -95,37 +92,3 @@ export declare enum CronExpression {
95
92
  MONDAY_TO_FRIDAY_AT_10PM = "0 0 22 * * 1-5",
96
93
  MONDAY_TO_FRIDAY_AT_11PM = "0 0 23 * * 1-5"
97
94
  }
98
- interface BaseUpsertIntegrationRequest<T extends IntegrationTypeWithConfig, C extends IntegrationConfig> {
99
- id: IntegrationId;
100
- type: T;
101
- config: Partial<C>;
102
- }
103
- type ConfigurationTypes = {
104
- [K in IntegrationTypeWithConfig]: IntegrationConfigTypes[K];
105
- };
106
- type UpsertIntegrationRequests = {
107
- [K in IntegrationTypeWithConfig]: BaseUpsertIntegrationRequest<K, ConfigurationTypes[K]>;
108
- };
109
- export type UpsertDataIntegrationRequest = UpsertIntegrationRequests[DatabaseIntegrationType];
110
- export type UpsertGraphQLIntegrationRequest = UpsertIntegrationRequests[IntegrationType.graphql];
111
- export type UpsertApiIntegrationRequest = UpsertIntegrationRequests[IntegrationType.api];
112
- export type UpsertAiChatbotIntegrationRequest = UpsertIntegrationRequests[IntegrationType.ai_chatbot];
113
- export type UpsertKafkaIntegrationRequest = UpsertIntegrationRequests[IntegrationType.kafka];
114
- export type UpsertConfluentIntegrationRequest = UpsertIntegrationRequests[IntegrationType.confluent];
115
- export type UpsertAuthIntegrationRequest = UpsertIntegrationRequests[AuthIntegrationType];
116
- interface BaseUpsertIntegrationSchemaRequest<T extends IntegrationType, S extends IntegrationSchema> {
117
- id: IntegrationId;
118
- type: T;
119
- schema: S;
120
- }
121
- type SchemaTypes = {
122
- [K in IntegrationSchemaKeys]: IntegrationSchemaTypes[K];
123
- };
124
- type UpsertIntegrationSchemaRequests = {
125
- [K in IntegrationSchemaKeys]: BaseUpsertIntegrationSchemaRequest<K, SchemaTypes[K]>;
126
- };
127
- export type UpsertIntegrationSchemaRequest = UpsertDataIntegrationSchemaRequest | UpsertGraphQLIntegrationSchemaRequest | UpsertApiIntegrationSchemaRequest;
128
- export type UpsertDataIntegrationSchemaRequest = UpsertIntegrationSchemaRequests[DatabaseIntegrationType];
129
- export type UpsertGraphQLIntegrationSchemaRequest = UpsertIntegrationSchemaRequests[IntegrationType.graphql];
130
- export type UpsertApiIntegrationSchemaRequest = UpsertIntegrationSchemaRequests[IntegrationType.api];
131
- export {};
@@ -0,0 +1,31 @@
1
+ import { AiModelName } from '../ai-chatbot.public-types';
2
+ export type AiChatbotConfiguration = {
3
+ apiKey?: string;
4
+ };
5
+ export type AiChatbotProfileMetadata = {
6
+ modelName: AiModelName;
7
+ isPublic: boolean;
8
+ strictContext: boolean;
9
+ instructions: Record<string, string>;
10
+ };
11
+ export type AiChatbotContextMetadata = {
12
+ title: string;
13
+ text: string;
14
+ preview: boolean;
15
+ sizeBytes?: number;
16
+ };
17
+ export type AiChatbotContextType = 'text' | 'url' | 'file';
18
+ interface AiChatbotContextBase {
19
+ type: AiChatbotContextType;
20
+ data: string;
21
+ }
22
+ export interface AiChatbotTextContext extends AiChatbotContextBase {
23
+ type: 'text';
24
+ }
25
+ export interface AiChatbotUrlContext extends AiChatbotContextBase {
26
+ type: 'url';
27
+ }
28
+ export interface AiChatbotFileContext extends AiChatbotContextBase {
29
+ type: 'file';
30
+ }
31
+ export {};
@@ -0,0 +1,41 @@
1
+ import { IntegrationType } from '../integration.public-types';
2
+ import { FieldName } from '../document.public-types';
3
+ export type HttpMethod = 'post' | 'get' | 'delete' | 'patch' | 'put';
4
+ export type ApiEndpointId = string;
5
+ export type ApiParameterLocation = 'query' | 'body' | 'header' | 'path';
6
+ export type ApiResponseParameterLocation = 'header' | 'body';
7
+ export type ApiInjectionParameterLocation = 'header' | 'query';
8
+ export type FieldPath = string;
9
+ export type IntegrationApiEndpoints = Record<ApiEndpointId, ApiEndpoint>;
10
+ export interface ApiRequestField {
11
+ location: ApiParameterLocation;
12
+ }
13
+ export interface ApiResponseField {
14
+ location: ApiResponseParameterLocation;
15
+ path?: FieldPath;
16
+ }
17
+ export type ApiInjectionFieldType = 'secret' | 'regular';
18
+ export interface ApiInjectionField {
19
+ value: string;
20
+ type: ApiInjectionFieldType;
21
+ location: ApiInjectionParameterLocation;
22
+ }
23
+ export interface GraphQLConnectionOptions {
24
+ baseUrl: string;
25
+ injectionSchema?: ApiInjectionSchema;
26
+ }
27
+ export type ApiInjectionSchema = Record<FieldName, ApiInjectionField>;
28
+ export interface OpenApiDiscoveryOptions {
29
+ openApiSpecUrl: string;
30
+ }
31
+ export interface ApiEndpoint {
32
+ relativePath: string;
33
+ method: HttpMethod;
34
+ requestSchema?: Record<FieldName, ApiRequestField>;
35
+ responseSchema?: Record<FieldPath, ApiResponseField>;
36
+ injectionSchema?: ApiInjectionSchema;
37
+ }
38
+ export interface DiscoverOpenApiSchemaRequest {
39
+ integrationType: IntegrationType.api;
40
+ discoveryOptions: OpenApiDiscoveryOptions;
41
+ }
@@ -54,7 +54,7 @@ export declare class Pagination<ReturnType> {
54
54
  /** Refreshes the current page of the pagination. */
55
55
  refreshPage(): Promise<PaginationState<ReturnType>>;
56
56
  /**
57
- * Jumps to the last page of the pagination. This page will always have the last <pageSize> elements of the
57
+ * Jumps to the last page of the pagination. This page will always have the last `pageSize` elements of the
58
58
  * underlying query, regardless of whether the total document count is evenly divisible by the page size.
59
59
  */
60
60
  last(): Promise<PaginationState<ReturnType>>;
@@ -38,6 +38,7 @@ export declare function isSimpleCondition(condition: Condition): condition is Si
38
38
  type CompositeConditionOperator = '>=' | '<=' | '>' | '<';
39
39
  /** An operator in a query condition. */
40
40
  export type Operator = '==' | '!=' | CompositeConditionOperator | 'like' | 'not like' | 'like_cs' | 'not like_cs';
41
+ export declare const ALL_OPERATORS: Array<Operator>;
41
42
  /** A definition of a sort by a filed. */
42
43
  export interface FieldSort<Doc> {
43
44
  fieldName: FieldName<Doc>;
@@ -14,3 +14,11 @@ export interface SecretEntry<T extends SecretValue = SecretValue> extends Secret
14
14
  export interface ApiKeyEntry extends SecretMetadata {
15
15
  value: string;
16
16
  }
17
+ export type SetSecretEntry = {
18
+ key: SecretKey;
19
+ value?: SecretValue;
20
+ };
21
+ export interface SetSecretRequestEntry {
22
+ key: SecretKey;
23
+ value: SecretValue;
24
+ }
@@ -1,2 +1 @@
1
- /** The query parameters of an API call. */
2
- export type ApiQueryParams = Record<string, string | number | boolean>;
1
+ export {};
@@ -1,11 +1,2 @@
1
- import { SecretKey, SecretValue } from '../public-types/secret.public-types';
2
- export type SetSecretEntry = {
3
- key: SecretKey;
4
- value?: SecretValue;
5
- };
6
1
  export declare const BACKEND_API_KEY = "_BACKEND_API_KEY";
7
2
  export declare const APP_API_KEY = "APP_API_KEY";
8
- export interface SetSecretRequestEntry {
9
- key: SecretKey;
10
- value: SecretValue;
11
- }
@@ -1,4 +1,4 @@
1
- export declare function getInPath(obj: Readonly<Record<string, unknown>>, path: string, delimiter?: string): any;
1
+ export declare function getInPath(obj: Readonly<any> | undefined, path: string, delimiter?: string): any;
2
2
  export declare function setInPath(obj: object, path: string, value: unknown, delimiter?: string): void;
3
3
  export declare function deleteInPath(obj: object, path: string, delimiter?: string): void;
4
4
  export declare function replaceKeyInMap<K, T>(map: Map<K, T | undefined>, a: K, b: K): void;
@@ -0,0 +1,15 @@
1
+ export declare function setSquidPrivateOption<T = unknown>(optionName: string, value: T): void;
2
+ export declare function getSquidPrivateOption<T = unknown>(optionName: string): T | undefined;
3
+ /*** Set of constants for private options. */
4
+ /**
5
+ * When set to 'true' (boolean), the RPC manager in Squid uses new 'fetch' based
6
+ * HTTP client instead of axios library.
7
+ * The option will be removed after the migration is tested and all issues are fixed.
8
+ */
9
+ export declare const SQUID_PRIVATE_OPTION_USE_FETCH_IN_RPC_MANAGER = "useFetchInRpcManager";
10
+ /**
11
+ * When set to 'true' (boolean), the Graphql client in Squid uses new 'fetch' based
12
+ * HTTP client instead of cross-fetch library.
13
+ * The option will be removed after the migration is tested and all issues are fixed.
14
+ */
15
+ export declare const SQUID_PRIVATE_OPTION_USE_FETCH_IN_GRAPHQL_CLIENT = "useFetchInGraphqlClient";
@@ -1,11 +1,12 @@
1
- export * from './public-types';
2
- export * from './public-utils';
3
1
  export { AiChatbotProfileReference } from './ai-chatbot-client';
4
- export { Changes, QueryBuilder } from './query/query-builder.factory';
5
2
  export { CollectionReference } from './collection-reference';
6
3
  export { DocumentReference } from './document-reference';
7
4
  export { GraphQLClient } from './graphql-client';
5
+ export * from './public-types';
6
+ export * from './public-utils';
7
+ export { deserializeQuery } from './query/deserializer';
8
8
  export { JoinQueryBuilder } from './query/join-query-builder.factory';
9
+ export { Changes, QueryBuilder } from './query/query-builder.factory';
10
+ export { QueueManager } from './queue.manager';
9
11
  export { Squid, SquidOptions } from './squid';
10
12
  export { TransactionId } from './types';
11
- export { deserializeQuery } from './query/deserializer';
@@ -14,13 +14,8 @@ export * from '../../internal-common/src/public-types/graphql.public-context';
14
14
  export * from '../../internal-common/src/public-types/graphql.public-types';
15
15
  export * from '../../internal-common/src/public-types/http-status.enum';
16
16
  export * from '../../internal-common/src/public-types/integration.public-types';
17
- export * from '../../internal-common/src/public-types/integrations/ai_chatbot.types';
18
- export * from '../../internal-common/src/public-types/integrations/api.types';
19
- export * from '../../internal-common/src/public-types/integrations/auth.types';
20
- export * from '../../internal-common/src/public-types/integrations/database.types';
21
- export * from '../../internal-common/src/public-types/integrations/observability.types';
22
- export * from '../../internal-common/src/public-types/integrations/queue-types';
23
- export * from '../../internal-common/src/public-types/integrations/schemas';
17
+ export * from '../../internal-common/src/public-types/integrations/ai_chatbot.public-types';
18
+ export * from '../../internal-common/src/public-types/integrations/api.public-types';
24
19
  export * from '../../internal-common/src/public-types/mutation.public-context';
25
20
  export * from '../../internal-common/src/public-types/mutation.public-types';
26
21
  export * from '../../internal-common/src/public-types/native-query.public-context';
@@ -1,5 +1,4 @@
1
- import { SetSecretRequestEntry } from '../../internal-common/src/types/secret.types';
2
- import { SecretEntry, SecretKey, SecretValue } from './public-types';
1
+ import { SecretEntry, SecretKey, SecretValue, SetSecretRequestEntry } from './public-types';
3
2
  import { RpcManager } from './rpc.manager';
4
3
  export declare class SecretClient {
5
4
  private readonly rpcManager;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@squidcloud/client",
3
- "version": "1.0.172",
3
+ "version": "1.0.174",
4
4
  "description": "A typescript implementation of the Squid client",
5
5
  "main": "dist/cjs/index.js",
6
6
  "types": "dist/typescript-client/src/index.d.ts",
@@ -15,7 +15,7 @@
15
15
  "watch": "webpack --watch",
16
16
  "lint": "eslint . --ext .ts",
17
17
  "build-and-check-public-types": "npm run prebuild && npm run build && npm run check-public-types",
18
- "check-public-types": "tsc -p tsconfig.types.json",
18
+ "check-public-types": "rimraf dist/internal-common/src/types dist/internal-common/src/utils && tsc -p tsconfig.types.json",
19
19
  "test": "jest --detectOpenHandles",
20
20
  "test:watch": "jest --watch",
21
21
  "test:cov": "jest --coverage",
@@ -1,32 +0,0 @@
1
- import { BaseIntegrationConfig } from './schemas';
2
- import { AiModelName } from '../ai-chatbot.public-types';
3
- import { IntegrationType } from '../integration.public-types';
4
- import { IntegrationId } from '../communication.public-types';
5
- export interface AiChatbotIntegrationConfig extends BaseIntegrationConfig {
6
- type: IntegrationType.ai_chatbot;
7
- configuration: AiChatbotConfiguration;
8
- }
9
- export type AiChatbotConfiguration = {
10
- apiKey?: string;
11
- };
12
- export type AiChatbotProfileMetadata = {
13
- modelName: AiModelName;
14
- isPublic: boolean;
15
- strictContext: boolean;
16
- instructions: Record<string, string>;
17
- };
18
- export type AiChatbotContextMetadata = {
19
- title: string;
20
- text: string;
21
- preview: boolean;
22
- sizeBytes?: number;
23
- };
24
- export interface AiChatbotProfile extends AiChatbotProfileMetadata {
25
- contexts: Record<string, AiChatbotContextMetadata>;
26
- }
27
- export interface AiChatbotProfiles {
28
- profiles: Record<string, AiChatbotProfile>;
29
- }
30
- export interface GetAiChatbotProfilesRequest {
31
- integrationId: IntegrationId;
32
- }
@@ -1,81 +0,0 @@
1
- import { BaseIntegrationConfig, BaseIntegrationSchema } from './schemas';
2
- import { IntegrationSchemaType, IntegrationType } from '../integration.public-types';
3
- import { IntrospectionQuery } from '../graphql.public-types';
4
- import { FieldName } from '../document.public-types';
5
- export type HttpMethod = 'post' | 'get' | 'delete' | 'patch' | 'put';
6
- export type ApiEndpointId = string;
7
- export type ApiParameterLocation = 'query' | 'body' | 'header' | 'path';
8
- export type ApiResponseParameterLocation = 'header' | 'body';
9
- export type ApiInjectionParameterLocation = 'header' | 'query';
10
- export type FieldPath = string;
11
- export type IntegrationApiEndpoints = Record<ApiEndpointId, ApiEndpoint>;
12
- export interface IntegrationGraphQLSchema extends BaseIntegrationSchema {
13
- type: IntegrationSchemaType.graphql;
14
- introspection: IntrospectionQuery;
15
- }
16
- export interface IntegrationApiSchema extends BaseIntegrationSchema {
17
- type: IntegrationSchemaType.api;
18
- baseUrl: string;
19
- endpoints: IntegrationApiEndpoints;
20
- injectionSchema?: ApiInjectionSchema;
21
- }
22
- export interface ApiRequestField {
23
- location: ApiParameterLocation;
24
- }
25
- export interface ApiResponseField {
26
- location: ApiResponseParameterLocation;
27
- path?: FieldPath;
28
- }
29
- export type ApiInjectionFieldType = 'secret' | 'regular';
30
- export interface ApiInjectionField {
31
- value: string;
32
- type: ApiInjectionFieldType;
33
- location: ApiInjectionParameterLocation;
34
- }
35
- export interface GraphQLConnectionOptions {
36
- baseUrl: string;
37
- injectionSchema?: ApiInjectionSchema;
38
- }
39
- export type ApiInjectionSchema = Record<FieldName, ApiInjectionField>;
40
- export interface OpenApiDiscoveryOptions {
41
- openApiSpecUrl: string;
42
- }
43
- export interface ApiEndpoint {
44
- relativePath: string;
45
- method: HttpMethod;
46
- requestSchema?: Record<FieldName, ApiRequestField>;
47
- responseSchema?: Record<FieldPath, ApiResponseField>;
48
- injectionSchema?: ApiInjectionSchema;
49
- }
50
- export interface HttpApiIntegrationConfig extends BaseIntegrationConfig {
51
- type: IntegrationType.api;
52
- configuration?: {
53
- discoveryOptions: OpenApiDiscoveryOptions;
54
- };
55
- }
56
- export interface GraphQLIntegrationConfig extends BaseIntegrationConfig {
57
- type: IntegrationType.graphql;
58
- configuration: {
59
- connectionOptions: GraphQLConnectionOptions;
60
- };
61
- }
62
- export interface DiscoverGraphQLConnectionSchemaRequest {
63
- integrationType: IntegrationType.graphql;
64
- connectionOptions: GraphQLConnectionOptions;
65
- }
66
- export interface DiscoverOpenApiSchemaRequest {
67
- integrationType: IntegrationType.api;
68
- discoveryOptions: OpenApiDiscoveryOptions;
69
- }
70
- export interface TestGraphQLDataConnectionRequest {
71
- type: IntegrationType.graphql;
72
- configuration: {
73
- connectionOptions: GraphQLConnectionOptions;
74
- };
75
- }
76
- export interface DiscoverGraphQLConnectionSchemaResponse {
77
- schema: IntegrationGraphQLSchema;
78
- }
79
- export interface DiscoverOpenApiSchemaResponse {
80
- schema: IntegrationApiSchema;
81
- }
@@ -1,54 +0,0 @@
1
- import { BaseIntegrationConfig } from './schemas';
2
- import { IntegrationType } from '../integration.public-types';
3
- export interface Auth0IntegrationConfig extends BaseIntegrationConfig {
4
- type: IntegrationType.auth0;
5
- configuration: {
6
- /** Auth0 domain. Used to build JWKS URL (https://$domain/.well-known/jwks.json) to check the JWT token signature.*/
7
- domain: string;
8
- /**
9
- * The Auth0 audience is a parameter that ensures the JWT token is intended for the specific backend being accessed.
10
- *
11
- * Note: the audience for the web-app auth token is equal to the Auth0 web client id: it means that the web app
12
- * client is a target audience for the JWT token. Such JWT tokens (ID tokens) should not be sent to the backend:
13
- * backend calls should use another kind of JWT tokens (access tokens) issued by Auth0 for the backends.
14
- */
15
- clientId: string;
16
- };
17
- }
18
- export interface CognitoIntegrationConfig extends BaseIntegrationConfig {
19
- type: IntegrationType.cognito;
20
- configuration: {
21
- region: string;
22
- userPoolId: string;
23
- appClientId: string;
24
- };
25
- }
26
- export interface OktaIntegrationConfig extends BaseIntegrationConfig {
27
- type: IntegrationType.okta;
28
- configuration: {
29
- domain: string;
30
- clientId: string;
31
- };
32
- }
33
- export interface JwtRsaIntegrationConfig extends BaseIntegrationConfig {
34
- type: IntegrationType.jwt_rsa;
35
- configuration: {
36
- jwksUri: string;
37
- validations?: {
38
- aud?: string;
39
- iss?: string;
40
- };
41
- };
42
- }
43
- export interface JwtHmacIntegrationConfig extends BaseIntegrationConfig {
44
- type: IntegrationType.jwt_hmac;
45
- configuration: {
46
- verifyUri?: string;
47
- };
48
- }
49
- export interface DescopeIntegrationConfig extends BaseIntegrationConfig {
50
- type: IntegrationType.descope;
51
- configuration: {
52
- projectId: string;
53
- };
54
- }