@squiz/dxp-ai-client
Advanced tools
Comparing version 0.24.0 to 0.25.0
# @squiz/dxp-ai-client | ||
## 0.25.0 | ||
### Minor Changes | ||
- 2d5288f: Updated dependencies to the latest version. | ||
## 0.24.0 | ||
@@ -4,0 +10,0 @@ |
@@ -18,3 +18,3 @@ export type AiAuthType = 'none' | 'dxp'; | ||
}; | ||
export type ChatbotCommand = 'closeThread' | 'processChatMessage' | 'processArticleAddUpdate' | 'processArticleDelete' | 'populateThreadTags' | 'populateThreadTitle'; | ||
export type ChatbotCommand = 'closeThread' | 'populateThreadTags' | 'populateThreadTitle' | 'processChatMessage' | 'processArticleAddUpdate' | 'processArticleDelete'; | ||
export interface Context { | ||
@@ -31,4 +31,18 @@ description: string; | ||
} | ||
export type CrawlState = 'idle' | 'crawling'; | ||
export interface CrawlerExecute { | ||
since?: string; | ||
} | ||
export type CrawlerPatch = PartialOmitCrawlerWriteAiId; | ||
export type CrawlerRead = OmitCrawlerLastCrawledAtOrScheduleArn; | ||
export interface CrawlerRule { | ||
contentExtraction?: RecordContentExtractionPropertyCssSelectorsArrayString; | ||
skip: boolean; | ||
url: string; | ||
} | ||
export type CrawlerType = 'sitemap'; | ||
export type CrawlerWrite = OmitCrawlerReadIdOrCrawlState; | ||
export interface DeleteParams { | ||
cleanupEmptyTenant?: boolean; | ||
hard?: boolean; | ||
id: string; | ||
@@ -38,2 +52,3 @@ } | ||
cleanupEmptyTenant?: boolean; | ||
hard?: boolean; | ||
id: string; | ||
@@ -44,3 +59,3 @@ } | ||
finishedAt: string | null; | ||
outputs: RecordStringActionFlowsGetExecutionOutputsActionEnumDatumReference3APath3F3AstringOrStringArrayReferenceIdStringTypeFlowsGetExecutionOutputsTypeEnum1ExperienceIdStringTypeFlowsGetExecutionOutputsTypeEnumValueStringOrNumberOrBooleanOrFlowsGetExecutionOutputsValueEnumOrRecordStringStringOrNumberOrBooleanOrFlowsGetExecutionOutputsValueEnum1OrFlowsGetExecutionOutputsValueEnum2OrActionFlowsGetExecutionOutputsActionEnum1DatumReference3APath3F3AstringOrStringArrayReferenceIdStringTypeFlowsGetExecutionOutputsTypeEnum3EntityIdStringOrNullExperienceIdStringSchemaIdStringTypeFlowsGetExecutionOutputsTypeEnum2OrActionFlowsGetExecutionOutputsActionEnum2To3ATypeFlowsGetExecutionOutputsTypeEnum5UrlStringOrPathStringTypeFlowsGetExecutionOutputsTypeEnum6OrDatumInputs3F3ARecordStringStringOrNumberOrBooleanOrFlowsGetExecutionOutputsDatumInputsEnumOrRecordStringStringOrNumberOrBooleanOrFlowsGetExecutionOutputsDatumInputsEnum1OrFlowsGetExecutionOutputsDatumInputsEnum2ExperienceIdStringExperiencePathStringSpaceIdStringTypeFlowsGetExecutionOutputsTypeEnum7OrEntityId3F3AstringOrNullSchemaIdStringSpaceIdStringTypeFlowsGetExecutionOutputsTypeEnum8TypeFlowsGetExecutionOutputsTypeEnum4OrFlowsGetExecutionOutputsOutputsEnumOrAnyOrStringOrNumberOrBooleanOrAllowedBlocks3F3AFlowsGetExecutionOutputsAllowedBlocksEnumArrayAllowedMarks3F3AFlowsGetExecutionOutputsAllowedMarksEnumArrayDescriptionStringOrNullHoveringToolbar3F3AbooleanNameStringOrderNumberRequiredBooleanOrNullShowInTable3F3AbooleanOrNullTypeFlowsGetExecutionOutputsTypeEnum9OrAnyArrayOrRecordStringAny; | ||
outputs: RecordString40ActionFlowsGetExecutionOutputsActionEnumDatumReference58Path63StringOrStringArrayReferenceIdStringTypeFlowsGetExecutionOutputsTypeEnum1ExperienceIdStringTypeFlowsGetExecutionOutputsTypeEnumValueStringOrNumberOrBooleanOrFlowsGetExecutionOutputsValueEnumOrRecordStringStringOrNumberOrBooleanOrFlowsGetExecutionOutputsValueEnum1OrFlowsGetExecutionOutputsValueEnum2OrActionFlowsGetExecutionOutputsActionEnum1DatumReference58Path63StringOrStringArrayReferenceIdStringTypeFlowsGetExecutionOutputsTypeEnum3EntityIdStringOrNullExperienceIdStringSchemaIdStringTypeFlowsGetExecutionOutputsTypeEnum2OrActionFlowsGetExecutionOutputsActionEnum2To58TypeFlowsGetExecutionOutputsTypeEnum5UrlStringOrPathStringTypeFlowsGetExecutionOutputsTypeEnum6OrDatumInputs63RecordStringStringOrNumberOrBooleanOrFlowsGetExecutionOutputsDatumInputsEnumOrRecordStringStringOrNumberOrBooleanOrFlowsGetExecutionOutputsDatumInputsEnum1OrFlowsGetExecutionOutputsDatumInputsEnum2ExperienceIdStringExperiencePathStringSpaceIdStringTypeFlowsGetExecutionOutputsTypeEnum7OrEntityId63StringOrNullSchemaIdStringSpaceIdStringTypeFlowsGetExecutionOutputsTypeEnum8TypeFlowsGetExecutionOutputsTypeEnum441Or40FlowsGetExecutionOutputsOutputsEnumOrAnyOrStringOrNumberOrBooleanOrAllowedBlocks63FlowsGetExecutionOutputsAllowedBlocksEnumArrayAllowedMarks63FlowsGetExecutionOutputsAllowedMarksEnumArrayDescription63StringOrNullHoveringToolbar63BooleanNameStringOrderNumberRequired63BooleanOrNullShowInTable63BooleanOrNullTypeFlowsGetExecutionOutputsTypeEnum9OrAnyArrayOrRecordStringAny41; | ||
startedAt: string | null; | ||
@@ -67,3 +82,3 @@ status: FlowsGetExecutionOutputsStatusEnum; | ||
export type FlowsGetExecutionOutputsStatusEnum = 'scheduled' | 'pending' | 'executing' | 'failed' | 'succeeded' | 'cancelled'; | ||
export type GenerativeCommand = 'closeThread' | 'populateThreadTags' | 'populateThreadTitle' | 'processMessage'; | ||
export type GenerativeCommand = 'closeThread' | 'processMessage' | 'populateThreadTags' | 'populateThreadTitle'; | ||
export type GenerativePatch = PartialGenerativeWrite; | ||
@@ -82,3 +97,3 @@ export type GenerativeWrite = AiWrite & { | ||
pageSize?: PaginationPageLimit; | ||
sortDirection?: SortDirectionEnum2; | ||
sortDirection?: SortDirectionEnum1; | ||
} | ||
@@ -94,3 +109,3 @@ export type GetAllChatBotThreadsParams1SortDirectionEnum = 'asc' | 'desc'; | ||
pageSize?: PaginationPageLimit; | ||
sortDirection?: SortDirectionEnum4; | ||
sortDirection?: SortDirectionEnum; | ||
} | ||
@@ -102,3 +117,3 @@ export type GetAllGenerativeThreadsParams1SortDirectionEnum = 'asc' | 'desc'; | ||
pageSize?: PaginationPageLimit; | ||
sortDirection?: SortDirectionEnum3; | ||
sortDirection?: SortDirectionEnum2; | ||
threadId: string; | ||
@@ -174,2 +189,9 @@ } | ||
export type JSONSchema7Version = string; | ||
export interface ListCrawlersParams { | ||
aiId?: string; | ||
cursor?: string; | ||
direction?: Direction; | ||
enabled?: boolean; | ||
pageSize?: PaginationPageLimit; | ||
} | ||
export interface ListParams { | ||
@@ -184,5 +206,7 @@ cursor?: string; | ||
aiId: string; | ||
contextId: string; | ||
cursor?: number; | ||
filter?: string; | ||
pageSize?: PaginationPageLimit; | ||
sortDirection?: SortDirectionEnum; | ||
sortDirection?: SortDirectionEnum3; | ||
} | ||
@@ -192,7 +216,5 @@ export type ListParams3SortDirectionEnum = 'asc' | 'desc'; | ||
aiId: string; | ||
contextId: string; | ||
cursor?: number; | ||
filter?: string; | ||
pageSize?: PaginationPageLimit; | ||
sortDirection?: SortDirectionEnum1; | ||
sortDirection?: SortDirectionEnum4; | ||
} | ||
@@ -215,2 +237,4 @@ export type ListParams5SortDirectionEnum = 'asc' | 'desc'; | ||
export type OmitAiTenantOrMetadata = PickAiExcludeKeysTenantOrMetadata; | ||
export type OmitCrawlerLastCrawledAtOrScheduleArn = PickCrawlerExcludeKeysLastCrawledAtOrScheduleArn; | ||
export type OmitCrawlerReadIdOrCrawlState = PickCrawlerReadExcludeKeysIdOrCrawlState; | ||
export type OmitJSONSchema7PropertiesOrItems = PickJSONSchema7ExcludeKeys7PropertiesOrItems; | ||
@@ -231,2 +255,9 @@ export interface PageResultAiResponse { | ||
} | ||
export interface PageResultCrawlerRead { | ||
items: CrawlerRead[]; | ||
links?: { | ||
nextPage?: string; | ||
prevPage?: string; | ||
}; | ||
} | ||
export interface PageResultMessage { | ||
@@ -261,6 +292,6 @@ items: Message[]; | ||
tags?: string[]; | ||
type?: AiType; | ||
type?: AiTypeChatbot; | ||
} | ||
export interface PartialGenerativeWrite { | ||
authType?: AiAuthType; | ||
authType?: AiAuthTypeDxp; | ||
enabled?: boolean; | ||
@@ -271,4 +302,11 @@ instruction?: string; | ||
tags?: string[]; | ||
type?: AiType; | ||
type?: AiTypeGenerative; | ||
} | ||
export interface PartialOmitCrawlerWriteAiId { | ||
enabled?: boolean; | ||
rules?: CrawlerRule[]; | ||
schedule?: string; | ||
type?: CrawlerType; | ||
url?: string; | ||
} | ||
export type PersistedContextItem = ContextItemAny & { | ||
@@ -295,2 +333,20 @@ id: string; | ||
} | ||
export interface PickCrawlerExcludeKeysLastCrawledAtOrScheduleArn { | ||
aiId: string; | ||
crawlState: CrawlState; | ||
enabled: boolean; | ||
id: string; | ||
rules: CrawlerRule[]; | ||
schedule: string; | ||
type: CrawlerType; | ||
url: string; | ||
} | ||
export interface PickCrawlerReadExcludeKeysIdOrCrawlState { | ||
aiId: string; | ||
enabled: boolean; | ||
rules: CrawlerRule[]; | ||
schedule: string; | ||
type: CrawlerType; | ||
url: string; | ||
} | ||
export interface PickJSONSchema7ExcludeKeys7PropertiesOrItems { | ||
@@ -303,3 +359,3 @@ $comment?: string; | ||
$ref?: string; | ||
$schema?: JSONSchema7Version; | ||
$schema?: string; | ||
additionalItems?: JSONSchema7Definition; | ||
@@ -318,3 +374,3 @@ additionalProperties?: JSONSchema7Definition; | ||
dependencies?: { | ||
[key: string]: JSONSchema7Definition | string[]; | ||
[key: string]: string[] | JSONSchema7Definition; | ||
}; | ||
@@ -359,3 +415,13 @@ description?: string; | ||
} | ||
export type RecordStringActionFlowsGetExecutionOutputsActionEnumDatumReference3APath3F3AstringOrStringArrayReferenceIdStringTypeFlowsGetExecutionOutputsTypeEnum1ExperienceIdStringTypeFlowsGetExecutionOutputsTypeEnumValueStringOrNumberOrBooleanOrFlowsGetExecutionOutputsValueEnumOrRecordStringStringOrNumberOrBooleanOrFlowsGetExecutionOutputsValueEnum1OrFlowsGetExecutionOutputsValueEnum2OrActionFlowsGetExecutionOutputsActionEnum1DatumReference3APath3F3AstringOrStringArrayReferenceIdStringTypeFlowsGetExecutionOutputsTypeEnum3EntityIdStringOrNullExperienceIdStringSchemaIdStringTypeFlowsGetExecutionOutputsTypeEnum2OrActionFlowsGetExecutionOutputsActionEnum2To3ATypeFlowsGetExecutionOutputsTypeEnum5UrlStringOrPathStringTypeFlowsGetExecutionOutputsTypeEnum6OrDatumInputs3F3ARecordStringStringOrNumberOrBooleanOrFlowsGetExecutionOutputsDatumInputsEnumOrRecordStringStringOrNumberOrBooleanOrFlowsGetExecutionOutputsDatumInputsEnum1OrFlowsGetExecutionOutputsDatumInputsEnum2ExperienceIdStringExperiencePathStringSpaceIdStringTypeFlowsGetExecutionOutputsTypeEnum7OrEntityId3F3AstringOrNullSchemaIdStringSpaceIdStringTypeFlowsGetExecutionOutputsTypeEnum8TypeFlowsGetExecutionOutputsTypeEnum4OrFlowsGetExecutionOutputsOutputsEnumOrAnyOrStringOrNumberOrBooleanOrAllowedBlocks3F3AFlowsGetExecutionOutputsAllowedBlocksEnumArrayAllowedMarks3F3AFlowsGetExecutionOutputsAllowedMarksEnumArrayDescriptionStringOrNullHoveringToolbar3F3AbooleanNameStringOrderNumberRequiredBooleanOrNullShowInTable3F3AbooleanOrNullTypeFlowsGetExecutionOutputsTypeEnum9OrAnyArrayOrRecordStringAny = object; | ||
export interface RecordContentExtractionPropertyCssSelectorsArrayString { | ||
content: { | ||
cssSelectors: string[]; | ||
}; | ||
title: { | ||
cssSelectors: string[]; | ||
}; | ||
} | ||
export type RecordString40ActionFlowsGetExecutionOutputsActionEnumDatumReference58Path63StringOrStringArrayReferenceIdStringTypeFlowsGetExecutionOutputsTypeEnum1ExperienceIdStringTypeFlowsGetExecutionOutputsTypeEnumValueStringOrNumberOrBooleanOrFlowsGetExecutionOutputsValueEnumOrRecordStringStringOrNumberOrBooleanOrFlowsGetExecutionOutputsValueEnum1OrFlowsGetExecutionOutputsValueEnum2OrActionFlowsGetExecutionOutputsActionEnum1DatumReference58Path63StringOrStringArrayReferenceIdStringTypeFlowsGetExecutionOutputsTypeEnum3EntityIdStringOrNullExperienceIdStringSchemaIdStringTypeFlowsGetExecutionOutputsTypeEnum2OrActionFlowsGetExecutionOutputsActionEnum2To58TypeFlowsGetExecutionOutputsTypeEnum5UrlStringOrPathStringTypeFlowsGetExecutionOutputsTypeEnum6OrDatumInputs63RecordStringStringOrNumberOrBooleanOrFlowsGetExecutionOutputsDatumInputsEnumOrRecordStringStringOrNumberOrBooleanOrFlowsGetExecutionOutputsDatumInputsEnum1OrFlowsGetExecutionOutputsDatumInputsEnum2ExperienceIdStringExperiencePathStringSpaceIdStringTypeFlowsGetExecutionOutputsTypeEnum7OrEntityId63StringOrNullSchemaIdStringSpaceIdStringTypeFlowsGetExecutionOutputsTypeEnum8TypeFlowsGetExecutionOutputsTypeEnum441Or40FlowsGetExecutionOutputsOutputsEnumOrAnyOrStringOrNumberOrBooleanOrAllowedBlocks63FlowsGetExecutionOutputsAllowedBlocksEnumArrayAllowedMarks63FlowsGetExecutionOutputsAllowedMarksEnumArrayDescription63StringOrNullHoveringToolbar63BooleanNameStringOrderNumberRequired63BooleanOrNullShowInTable63BooleanOrNullTypeFlowsGetExecutionOutputsTypeEnum9OrAnyArrayOrRecordStringAny41 = { | ||
[key: string]: any; | ||
}; | ||
export type SortDirectionEnum = 'asc' | 'desc'; | ||
@@ -383,7 +449,7 @@ export type SortDirectionEnum1 = 'asc' | 'desc'; | ||
export type ThreadRatingPositive = 'positive'; | ||
export declare namespace Chatbot { | ||
export declare namespace Generative { | ||
namespace Create { | ||
type RequestParams = {}; | ||
type RequestQuery = {}; | ||
type RequestBody = ChatBotWrite; | ||
type RequestBody = GenerativeWrite; | ||
type RequestHeaders = {}; | ||
@@ -398,2 +464,3 @@ type ResponseBody = AiResponse; | ||
cleanupEmptyTenant?: boolean; | ||
hard?: boolean; | ||
}; | ||
@@ -404,2 +471,12 @@ type RequestBody = never; | ||
} | ||
namespace Execute { | ||
type RequestParams = { | ||
aiId: string; | ||
flowId: GenerativeCommand; | ||
}; | ||
type RequestQuery = {}; | ||
type RequestBody = ExecutionPostBody; | ||
type RequestHeaders = {}; | ||
type ResponseBody = ExecutionResponse; | ||
} | ||
namespace Get { | ||
@@ -414,3 +491,3 @@ type RequestParams = { | ||
} | ||
namespace GetAllChatBotThreads { | ||
namespace GetAllGenerativeThreads { | ||
type RequestParams = { | ||
@@ -426,3 +503,3 @@ aiId: string; | ||
pageSize?: PaginationPageLimit; | ||
sortDirection?: GetAllChatBotThreadsParams1SortDirectionEnum; | ||
sortDirection?: GetAllGenerativeThreadsParams1SortDirectionEnum; | ||
}; | ||
@@ -433,15 +510,22 @@ type RequestBody = never; | ||
} | ||
namespace GetChatBotThreadMessages { | ||
namespace GetExecutionOutput { | ||
type RequestParams = { | ||
aiId: string; | ||
executionId: string; | ||
flowId: GenerativeCommand; | ||
}; | ||
type RequestQuery = {}; | ||
type RequestBody = never; | ||
type RequestHeaders = {}; | ||
type ResponseBody = ExecutionOutputsResponse; | ||
} | ||
namespace GetGenerativeThreadQueryAndResponse { | ||
type RequestParams = { | ||
aiId: string; | ||
threadId: string; | ||
}; | ||
type RequestQuery = { | ||
cursor?: number; | ||
pageSize?: PaginationPageLimit; | ||
sortDirection?: GetChatBotThreadMessagesParams1SortDirectionEnum; | ||
}; | ||
type RequestQuery = {}; | ||
type RequestBody = never; | ||
type RequestHeaders = {}; | ||
type ResponseBody = PageResultMessage; | ||
type ResponseBody = Message; | ||
} | ||
@@ -471,2 +555,11 @@ namespace List { | ||
} | ||
namespace Restore { | ||
type RequestParams = { | ||
id: string; | ||
}; | ||
type RequestQuery = {}; | ||
type RequestBody = never; | ||
type RequestHeaders = {}; | ||
type ResponseBody = void; | ||
} | ||
namespace Set { | ||
@@ -477,3 +570,3 @@ type RequestParams = { | ||
type RequestQuery = {}; | ||
type RequestBody = ChatBotWrite; | ||
type RequestBody = GenerativeWrite; | ||
type RequestHeaders = {}; | ||
@@ -487,3 +580,3 @@ type ResponseBody = AiResponse; | ||
type RequestQuery = {}; | ||
type RequestBody = ChatBotPatch; | ||
type RequestBody = GenerativePatch; | ||
type RequestHeaders = {}; | ||
@@ -493,14 +586,32 @@ type ResponseBody = AiResponse; | ||
} | ||
export declare namespace ChatbotContext { | ||
namespace GetSchema { | ||
export declare namespace Chatbot { | ||
namespace Create { | ||
type RequestParams = {}; | ||
type RequestQuery = {}; | ||
type RequestBody = ChatBotWrite; | ||
type RequestHeaders = {}; | ||
type ResponseBody = AiResponse; | ||
} | ||
namespace Delete { | ||
type RequestParams = { | ||
aiId: string; | ||
contextId: string; | ||
id: string; | ||
}; | ||
type RequestQuery = { | ||
cleanupEmptyTenant?: boolean; | ||
hard?: boolean; | ||
}; | ||
type RequestBody = never; | ||
type RequestHeaders = {}; | ||
type ResponseBody = void; | ||
} | ||
namespace Get { | ||
type RequestParams = { | ||
id: string; | ||
}; | ||
type RequestQuery = {}; | ||
type RequestBody = never; | ||
type RequestHeaders = {}; | ||
type ResponseBody = ExtendedJsonSchema; | ||
type ResponseBody = AiResponse; | ||
} | ||
namespace List { | ||
namespace GetAllChatBotThreads { | ||
type RequestParams = { | ||
@@ -511,37 +622,53 @@ aiId: string; | ||
cursor?: number; | ||
filterByCSVTagString?: string; | ||
filterByDateFrom?: string; | ||
filterByDateTo?: string; | ||
filterByRating?: ThreadRatingParameter; | ||
pageSize?: PaginationPageLimit; | ||
sortDirection?: ListParams3SortDirectionEnum; | ||
sortDirection?: GetAllChatBotThreadsParams1SortDirectionEnum; | ||
}; | ||
type RequestBody = never; | ||
type RequestHeaders = {}; | ||
type ResponseBody = PageResultContext; | ||
type ResponseBody = PageResultThread; | ||
} | ||
} | ||
export declare namespace ChatbotContextItem { | ||
namespace Create { | ||
namespace GetChatBotThreadMessages { | ||
type RequestParams = { | ||
aiId: string; | ||
contextId: string; | ||
threadId: string; | ||
}; | ||
type RequestQuery = {}; | ||
type RequestBody = ContextItem; | ||
type RequestQuery = { | ||
cursor?: number; | ||
pageSize?: PaginationPageLimit; | ||
sortDirection?: GetChatBotThreadMessagesParams1SortDirectionEnum; | ||
}; | ||
type RequestBody = never; | ||
type RequestHeaders = {}; | ||
type ResponseBody = PersistedContextItem; | ||
type ResponseBody = PageResultMessage; | ||
} | ||
namespace Delete { | ||
namespace List { | ||
type RequestParams = {}; | ||
type RequestQuery = { | ||
cursor?: string; | ||
direction?: Direction; | ||
enabled?: boolean; | ||
pageSize?: PaginationPageLimit; | ||
tags?: string[]; | ||
}; | ||
type RequestBody = never; | ||
type RequestHeaders = {}; | ||
type ResponseBody = PageResultAiResponse; | ||
} | ||
namespace Rate { | ||
type RequestParams = { | ||
aiId: string; | ||
contextId: string; | ||
contextItemId: string; | ||
threadId: string; | ||
}; | ||
type RequestQuery = {}; | ||
type RequestBody = never; | ||
type RequestBody = RateBody; | ||
type RequestHeaders = {}; | ||
type ResponseBody = void; | ||
type ResponseBody = Thread; | ||
} | ||
namespace Get { | ||
namespace Restore { | ||
type RequestParams = { | ||
aiId: string; | ||
contextId: string; | ||
contextItemId: string; | ||
id: string; | ||
}; | ||
@@ -551,29 +678,21 @@ type RequestQuery = {}; | ||
type RequestHeaders = {}; | ||
type ResponseBody = PersistedContextItem; | ||
type ResponseBody = void; | ||
} | ||
namespace List { | ||
namespace Set { | ||
type RequestParams = { | ||
aiId: string; | ||
contextId: string; | ||
id: string; | ||
}; | ||
type RequestQuery = { | ||
cursor?: number; | ||
filter?: string; | ||
pageSize?: PaginationPageLimit; | ||
sortDirection?: ListParams5SortDirectionEnum; | ||
}; | ||
type RequestBody = never; | ||
type RequestQuery = {}; | ||
type RequestBody = ChatBotWrite; | ||
type RequestHeaders = {}; | ||
type ResponseBody = PageResultPersistedContextItem; | ||
type ResponseBody = AiResponse; | ||
} | ||
namespace Update { | ||
type RequestParams = { | ||
aiId: string; | ||
contextId: string; | ||
contextItemId: string; | ||
id: string; | ||
}; | ||
type RequestQuery = {}; | ||
type RequestBody = PersistedContextItem; | ||
type RequestBody = ChatBotPatch; | ||
type RequestHeaders = {}; | ||
type ResponseBody = PersistedContextItem; | ||
type ResponseBody = AiResponse; | ||
} | ||
@@ -604,17 +723,24 @@ } | ||
} | ||
export declare namespace Generative { | ||
namespace Create { | ||
export declare namespace Crawlers { | ||
namespace Crawl { | ||
type RequestParams = { | ||
crawlerId: string; | ||
}; | ||
type RequestQuery = {}; | ||
type RequestBody = CrawlerExecute; | ||
type RequestHeaders = {}; | ||
type ResponseBody = void; | ||
} | ||
namespace CreateCrawler { | ||
type RequestParams = {}; | ||
type RequestQuery = {}; | ||
type RequestBody = GenerativeWrite; | ||
type RequestBody = CrawlerWrite; | ||
type RequestHeaders = {}; | ||
type ResponseBody = AiResponse; | ||
type ResponseBody = CrawlerRead; | ||
} | ||
namespace Delete { | ||
namespace DeleteCrawler { | ||
type RequestParams = { | ||
id: string; | ||
crawlerId: string; | ||
}; | ||
type RequestQuery = { | ||
cleanupEmptyTenant?: boolean; | ||
}; | ||
type RequestQuery = {}; | ||
type RequestBody = never; | ||
@@ -624,43 +750,50 @@ type RequestHeaders = {}; | ||
} | ||
namespace Execute { | ||
namespace Get { | ||
type RequestParams = { | ||
aiId: string; | ||
flowId: GenerativeCommand; | ||
crawlerId: string; | ||
}; | ||
type RequestQuery = {}; | ||
type RequestBody = ExecutionPostBody; | ||
type RequestBody = never; | ||
type RequestHeaders = {}; | ||
type ResponseBody = ExecutionResponse; | ||
type ResponseBody = CrawlerRead; | ||
} | ||
namespace Get { | ||
namespace ListCrawlers { | ||
type RequestParams = {}; | ||
type RequestQuery = { | ||
aiId?: string; | ||
cursor?: string; | ||
direction?: Direction; | ||
enabled?: boolean; | ||
pageSize?: PaginationPageLimit; | ||
}; | ||
type RequestBody = never; | ||
type RequestHeaders = {}; | ||
type ResponseBody = PageResultCrawlerRead; | ||
} | ||
namespace UpdateCrawler { | ||
type RequestParams = { | ||
id: string; | ||
crawlerId: string; | ||
}; | ||
type RequestQuery = {}; | ||
type RequestBody = never; | ||
type RequestBody = CrawlerPatch; | ||
type RequestHeaders = {}; | ||
type ResponseBody = AiResponse; | ||
type ResponseBody = CrawlerRead; | ||
} | ||
namespace GetAllGenerativeThreads { | ||
} | ||
export declare namespace ChatbotContextItem { | ||
namespace Create { | ||
type RequestParams = { | ||
aiId: string; | ||
contextId: string; | ||
}; | ||
type RequestQuery = { | ||
cursor?: number; | ||
filterByCSVTagString?: string; | ||
filterByDateFrom?: string; | ||
filterByDateTo?: string; | ||
filterByRating?: ThreadRatingParameter; | ||
pageSize?: PaginationPageLimit; | ||
sortDirection?: GetAllGenerativeThreadsParams1SortDirectionEnum; | ||
}; | ||
type RequestBody = never; | ||
type RequestQuery = {}; | ||
type RequestBody = ContextItem; | ||
type RequestHeaders = {}; | ||
type ResponseBody = PageResultThread; | ||
type ResponseBody = PersistedContextItem; | ||
} | ||
namespace GetExecutionOutput { | ||
namespace Delete { | ||
type RequestParams = { | ||
aiId: string; | ||
executionId: string; | ||
flowId: GenerativeCommand; | ||
contextId: string; | ||
contextItemId: string; | ||
}; | ||
@@ -670,8 +803,9 @@ type RequestQuery = {}; | ||
type RequestHeaders = {}; | ||
type ResponseBody = ExecutionOutputsResponse; | ||
type ResponseBody = void; | ||
} | ||
namespace GetGenerativeThreadQueryAndResponse { | ||
namespace Get { | ||
type RequestParams = { | ||
aiId: string; | ||
threadId: string; | ||
contextId: string; | ||
contextItemId: string; | ||
}; | ||
@@ -681,44 +815,54 @@ type RequestQuery = {}; | ||
type RequestHeaders = {}; | ||
type ResponseBody = Message; | ||
type ResponseBody = PersistedContextItem; | ||
} | ||
namespace List { | ||
type RequestParams = {}; | ||
type RequestParams = { | ||
aiId: string; | ||
contextId: string; | ||
}; | ||
type RequestQuery = { | ||
cursor?: string; | ||
direction?: Direction; | ||
enabled?: boolean; | ||
cursor?: number; | ||
filter?: string; | ||
pageSize?: PaginationPageLimit; | ||
tags?: string[]; | ||
sortDirection?: ListParams3SortDirectionEnum; | ||
}; | ||
type RequestBody = never; | ||
type RequestHeaders = {}; | ||
type ResponseBody = PageResultAiResponse; | ||
type ResponseBody = PageResultPersistedContextItem; | ||
} | ||
namespace Rate { | ||
namespace Update { | ||
type RequestParams = { | ||
aiId: string; | ||
threadId: string; | ||
contextId: string; | ||
contextItemId: string; | ||
}; | ||
type RequestQuery = {}; | ||
type RequestBody = RateBody; | ||
type RequestBody = PersistedContextItem; | ||
type RequestHeaders = {}; | ||
type ResponseBody = Thread; | ||
type ResponseBody = PersistedContextItem; | ||
} | ||
namespace Set { | ||
} | ||
export declare namespace ChatbotContext { | ||
namespace GetSchema { | ||
type RequestParams = { | ||
id: string; | ||
aiId: string; | ||
contextId: string; | ||
}; | ||
type RequestQuery = {}; | ||
type RequestBody = GenerativeWrite; | ||
type RequestBody = never; | ||
type RequestHeaders = {}; | ||
type ResponseBody = AiResponse; | ||
type ResponseBody = ExtendedJsonSchema; | ||
} | ||
namespace Update { | ||
namespace List { | ||
type RequestParams = { | ||
id: string; | ||
aiId: string; | ||
}; | ||
type RequestQuery = {}; | ||
type RequestBody = GenerativePatch; | ||
type RequestQuery = { | ||
cursor?: number; | ||
pageSize?: PaginationPageLimit; | ||
sortDirection?: ListParams5SortDirectionEnum; | ||
}; | ||
type RequestBody = never; | ||
type RequestHeaders = {}; | ||
type ResponseBody = AiResponse; | ||
type ResponseBody = PageResultContext; | ||
} | ||
@@ -779,17 +923,40 @@ } | ||
constructor(http: HttpClient<SecurityDataType>); | ||
generative: { | ||
create: (data: GenerativeWrite, params?: RequestParams) => Promise<AiResponse>; | ||
delete: ({ id, ...query }: DeleteParams, params?: RequestParams) => Promise<void>; | ||
execute: (aiId: string, flowId: GenerativeCommand, data: ExecutionPostBody, params?: RequestParams) => Promise<ExecutionResponse>; | ||
get: (id: string, params?: RequestParams) => Promise<AiResponse>; | ||
getAllGenerativeThreads: ({ aiId, ...query }: GetAllGenerativeThreadsParams, params?: RequestParams) => Promise<PageResultThread>; | ||
getExecutionOutput: (aiId: string, flowId: GenerativeCommand, executionId: string, params?: RequestParams) => Promise<ExecutionOutputsResponse>; | ||
getGenerativeThreadQueryAndResponse: (aiId: string, threadId: string, params?: RequestParams) => Promise<Message>; | ||
list: (query: ListParams, params?: RequestParams) => Promise<PageResultAiResponse>; | ||
rate: (aiId: string, threadId: string, data: RatePayload, params?: RequestParams) => Promise<Thread>; | ||
restore: (id: string, params?: RequestParams) => Promise<void>; | ||
set: (id: string, data: GenerativeWrite, params?: RequestParams) => Promise<AiResponse>; | ||
update: (id: string, data: GenerativePatch, params?: RequestParams) => Promise<AiResponse>; | ||
}; | ||
chatbot: { | ||
create: (data: ChatBotWrite, params?: RequestParams) => Promise<AiResponse>; | ||
delete: ({ id, ...query }: DeleteParams, params?: RequestParams) => Promise<void>; | ||
delete: ({ id, ...query }: DeleteParams3, params?: RequestParams) => Promise<void>; | ||
get: (id: string, params?: RequestParams) => Promise<AiResponse>; | ||
getAllChatBotThreads: ({ aiId, ...query }: GetAllChatBotThreadsParams, params?: RequestParams) => Promise<PageResultThread>; | ||
getChatBotThreadMessages: ({ aiId, threadId, ...query }: GetChatBotThreadMessagesParams, params?: RequestParams) => Promise<PageResultMessage>; | ||
list: (query: ListParams, params?: RequestParams) => Promise<PageResultAiResponse>; | ||
rate: (aiId: string, threadId: string, data: RatePayload, params?: RequestParams) => Promise<Thread>; | ||
list: (query: ListParams6, params?: RequestParams) => Promise<PageResultAiResponse>; | ||
rate: (aiId: string, threadId: string, data: RateBody, params?: RequestParams) => Promise<Thread>; | ||
restore: (id: string, params?: RequestParams) => Promise<void>; | ||
set: (id: string, data: ChatBotWrite, params?: RequestParams) => Promise<AiResponse>; | ||
update: (id: string, data: ChatBotPatch, params?: RequestParams) => Promise<AiResponse>; | ||
}; | ||
chatbotContext: { | ||
getSchema: (aiId: string, contextId: string, params?: RequestParams) => Promise<ExtendedJsonSchema>; | ||
list: ({ aiId, ...query }: ListParams2, params?: RequestParams) => Promise<PageResultContext>; | ||
chatbotExecution: { | ||
execute: (aiId: string, command: ChatbotCommand, data: ExecutionPostBody, params?: RequestParams) => Promise<ExecutionResponse>; | ||
getExecutionOutput: (aiId: string, command: ChatbotCommand, executionId: string, params?: RequestParams) => Promise<ExecutionOutputsResponse>; | ||
}; | ||
crawlers: { | ||
crawl: (crawlerId: string, data: CrawlerExecute, params?: RequestParams) => Promise<void>; | ||
createCrawler: (data: CrawlerWrite, params?: RequestParams) => Promise<PickCrawlerExcludeKeysLastCrawledAtOrScheduleArn>; | ||
deleteCrawler: (crawlerId: string, params?: RequestParams) => Promise<void>; | ||
get: (crawlerId: string, params?: RequestParams) => Promise<PickCrawlerExcludeKeysLastCrawledAtOrScheduleArn>; | ||
listCrawlers: (query: ListCrawlersParams, params?: RequestParams) => Promise<PageResultCrawlerRead>; | ||
updateCrawler: (crawlerId: string, data: CrawlerPatch, params?: RequestParams) => Promise<PickCrawlerExcludeKeysLastCrawledAtOrScheduleArn>; | ||
}; | ||
chatbotContextItem: { | ||
@@ -799,23 +966,10 @@ create: (aiId: string, contextId: string, data: ContextItem, params?: RequestParams) => Promise<PersistedContextItem>; | ||
get: (aiId: string, contextId: string, contextItemId: string, params?: RequestParams) => Promise<PersistedContextItem>; | ||
list: ({ aiId, contextId, ...query }: ListParams4, params?: RequestParams) => Promise<PageResultPersistedContextItem>; | ||
list: ({ aiId, contextId, ...query }: ListParams2, params?: RequestParams) => Promise<PageResultPersistedContextItem>; | ||
update: (aiId: string, contextId: string, contextItemId: string, data: PersistedContextItem, params?: RequestParams) => Promise<PersistedContextItem>; | ||
}; | ||
chatbotExecution: { | ||
execute: (aiId: string, command: ChatbotCommand, data: ExecutionPostBody, params?: RequestParams) => Promise<ExecutionResponse>; | ||
getExecutionOutput: (aiId: string, command: ChatbotCommand, executionId: string, params?: RequestParams) => Promise<ExecutionOutputsResponse>; | ||
chatbotContext: { | ||
getSchema: (aiId: string, contextId: string, params?: RequestParams) => Promise<ExtendedJsonSchema>; | ||
list: ({ aiId, ...query }: ListParams4, params?: RequestParams) => Promise<PageResultContext>; | ||
}; | ||
generative: { | ||
create: (data: GenerativeWrite, params?: RequestParams) => Promise<AiResponse>; | ||
delete: ({ id, ...query }: DeleteParams3, params?: RequestParams) => Promise<void>; | ||
execute: (aiId: string, flowId: GenerativeCommand, data: ExecutionPostBody, params?: RequestParams) => Promise<ExecutionResponse>; | ||
get: (id: string, params?: RequestParams) => Promise<AiResponse>; | ||
getAllGenerativeThreads: ({ aiId, ...query }: GetAllGenerativeThreadsParams, params?: RequestParams) => Promise<PageResultThread>; | ||
getExecutionOutput: (aiId: string, flowId: GenerativeCommand, executionId: string, params?: RequestParams) => Promise<ExecutionOutputsResponse>; | ||
getGenerativeThreadQueryAndResponse: (aiId: string, threadId: string, params?: RequestParams) => Promise<Message>; | ||
list: (query: ListParams6, params?: RequestParams) => Promise<PageResultAiResponse>; | ||
rate: (aiId: string, threadId: string, data: RateBody, params?: RequestParams) => Promise<Thread>; | ||
set: (id: string, data: GenerativeWrite, params?: RequestParams) => Promise<AiResponse>; | ||
update: (id: string, data: GenerativePatch, params?: RequestParams) => Promise<AiResponse>; | ||
}; | ||
} | ||
export {}; |
@@ -45,2 +45,2 @@ "use strict"; | ||
generate().then(() => console.log('generated')); | ||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZ2VuZXJhdGUuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi9zcmMvZ2VuZXJhdG9yL2dlbmVyYXRlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7Ozs7O0FBK0VBLDJCQVFDO0FBdkZELG1FQUF3RTtBQUN4RSxnREFBd0I7QUFJeEIsTUFBTSxNQUFNLEdBQStCO0lBQ3pDLE1BQU0sRUFBRSxjQUFJLENBQUMsT0FBTyxDQUFDLE9BQU8sQ0FBQyxHQUFHLEVBQUUsRUFBRSxpQkFBaUIsQ0FBQztJQUl0RCxjQUFjLEVBQUUsT0FBTztJQ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ZW5lcmF0ZUFwaSh7XG4gICAgICAuLi5wYXJhbXMsXG4gICAgICBuYW1lOiAnRHhwQWlTZXJ2aWNlLnRzJyxcbiAgICAgIGlucHV0OiBwYXRoLnJlc29sdmUoX19kaXJuYW1lLCAnLi4vLi4vLi4vLi4vYXBwbGljYXRpb25zL2FpLXNlcnZpY2UvZGlzdC9zd2FnZ2VyLmpzb24nKSxcbiAgICB9KSxcbiAgXSk7XG59XG5cbmdlbmVyYXRlKCkudGhlbigoKSA9PiBjb25zb2xlLmxvZygnZ2VuZXJhdGVkJykpO1xuIl19 |
@@ -9,4 +9,5 @@ "use strict"; | ||
const swagger_typescript_api_1 = require("swagger-typescript-api"); | ||
jest.mock('swagger-typescript-api'); | ||
jest.useRealTimers(); | ||
jest.mock('swagger-typescript-api', () => ({ | ||
generateApi: jest.fn(), | ||
})); | ||
describe('generate function', () => { | ||
@@ -33,2 +34,2 @@ it('should call generateApi with correct params', async () => { | ||
}); | ||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZ2VuZXJhdGUuc3BlYy5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uL3NyYy9nZW5lcmF0b3IvZ2VuZXJhdGUuc3BlYy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOzs7OztBQUFBLGdEQUF3QjtBQUN4QiwwREFBa0M7QUFDbEMsbUVBQTBGO0FBRTFGLElBQUksQ0FBQyxJQUFJLENBQUMsd0JBQXdCLENBQUMsQ0FBQztBQUNwQyxJQUFJLENBQUMsYUFBYSxFQUFFLENBQUM7QUFFckIsUUFBUSxDQUFDLG1CQUFtQixFQUFFLEdBQUcsRUFBRTtJQUNqQyxFQUFFLENBQUMsNkNBQTZDLEVBQUUsS0FBSyxJQUFJLEVBQUU7UUFDM0QsTUFBTSxNQUFNLEdBQStCO1lBQ3pDLGNBQWMsRUFBRSxPQUFPO1lBQ3ZCLElBQUksRUFBRSxpQ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(error) { | ||
catch { | ||
const responseClone = response.clone(); | ||
@@ -24,2 +24,2 @@ const responseBody = await responseClone.text(); | ||
exports.handleResponseError = handleResponseError; | ||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaGFuZGxlUmVzcG9uc2VFcnJvci5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uL3NyYy91dGlscy9oYW5kbGVSZXNwb25zZUVycm9yL2hhbmRsZVJlc3BvbnNlRXJyb3IudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7O0FBQUEsb0ZBQWlGO0FBRTFFLE1BQU0sbUJBQW1CLEdBQUcsS0FBSyxFQUFFLFFBQWtCLEVBQUUsRUFBRTtJQUM5RCxJQUFJLE9BQU8sR0FBRyw0QkFBNEIsQ0FBQztJQUMzQyxJQUFJLE9BQU8sR0FBRyxrQ0FBa0MsQ0FBQztJQUNqRCxJQUFJLENBQUM7UUFDSCxNQUFNLGFBQWEsR0FBRyxRQUFRLENBQUMsS0FBSyxFQUFFLENBQUM7UUFDdkMsTUFBTSxJQUFJLEdBQUcsTUFBTSxhQUFhLENBQUMsSUFBSSxFQUFFLENBQUM7UUFDeEMsT0FBTyxHQUFHLElBQUksQ0FBQyxPQUFPLElBQUksT0FBTyxDQUFDO1FBQ2xDLE9BQU8sR0FBRyxJQUFJLENBQUMsT0FBTyxJQUFJLE9BQU8sQ0FBQztJQUNwQyxDQUFDO0lBQUMsT0FBTyxLQUFLLEVBQUUsQ0FBQztRQUNmLE1BQU0sYUFBYSxHQUFHLFFBQVEsQ0FBQyxLQUFLLEVBQUUsQ0FBQztRQUN2QyxNQUFNLFlBQVksR0FBRyxNQUFNLGFBQWEsQ0FBQyxJQUFJLEVBQUUsQ0FBQztRQUNoRCxPQUFPLEdBQUcsb0RBQW9ELFlBQVksRUFBRSxDQUFDO1FBQzdFLE1BQU0sSUFBSSx5Q0FBbUIsQ0FBQyxRQUFR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tcbiAgICBjb25zdCByZXNwb25zZUJvZHkgPSBhd2FpdCByZXNwb25zZUNsb25lLnRleHQoKTtcbiAgICBtZXNzYWdlID0gYEZhaWxlZCB0byBwYXJzZSByZXNwb25zZSBib2R5IGFzIEpTT04uIFJlc3BvbnNlOiAke3Jlc3BvbnNlQm9keX1gO1xuICAgIHRocm93IG5ldyBDbGllbnRSZXNwb25zZUVycm9yKHJlc3BvbnNlLnN0YXR1cywgbWVzc2FnZSwgZGV0YWlscywgcmVzcG9uc2UpO1xuICB9XG4gIHRocm93IG5ldyBDbGllbnRSZXNwb25zZUVycm9yKHJlc3BvbnNlLnN0YXR1cywgbWVzc2FnZSwgZGV0YWlscywgcmVzcG9uc2UpO1xufTtcbiJdfQ== |
@@ -8,3 +8,3 @@ { | ||
}, | ||
"version": "0.24.0", | ||
"version": "0.25.0", | ||
"description": "Exposes the DXP AI service as a package for consumers", | ||
@@ -21,7 +21,7 @@ "main": "dist/index.js", | ||
"devDependencies": { | ||
"@squiz/ai-service": "1.17.0", | ||
"@squiz/ai-service": "1.34.0", | ||
"jest": "^29.7.0", | ||
"swagger-typescript-api": "^13.0.3", | ||
"typescript": "^5.5.3" | ||
"swagger-typescript-api": "^13.0.22", | ||
"typescript": "^5.5.4" | ||
} | ||
} |
import path from 'path'; | ||
import generate from './generate'; | ||
import { CodeGenConstruct, generateApi, GenerateApiParams } from 'swagger-typescript-api'; | ||
import { generateApi, GenerateApiParams } from 'swagger-typescript-api'; | ||
jest.mock('swagger-typescript-api'); | ||
jest.useRealTimers(); | ||
jest.mock('swagger-typescript-api', () => ({ | ||
generateApi: jest.fn(), | ||
})); | ||
@@ -25,4 +26,4 @@ describe('generate function', () => { | ||
const { codeGenConstructs } = params; | ||
const defaultConstructs = { ArrayType: jest.fn() } as unknown as CodeGenConstruct; | ||
const constructs = codeGenConstructs?.(defaultConstructs); | ||
const defaultConstructs = { ArrayType: jest.fn() }; | ||
const constructs = codeGenConstructs?.(defaultConstructs as never); | ||
const recordType = constructs?.RecordType as (...args: string[]) => string; | ||
@@ -29,0 +30,0 @@ |
@@ -72,3 +72,3 @@ import { generateApi, GenerateApiParams } from 'swagger-typescript-api'; | ||
...constructs, | ||
RecordType: (...args: string[]): string => { | ||
RecordType: (...args: unknown[]): string => { | ||
// Avoid "Type alias 'X' circularly references itself." which can occur with Record<key, value>. | ||
@@ -75,0 +75,0 @@ const [key, value] = args; |
@@ -11,3 +11,3 @@ import { ClientResponseError } from '../ClientResponseError/ClientResponseError'; | ||
details = body.details || details; | ||
} catch (error) { | ||
} catch { | ||
const responseClone = response.clone(); | ||
@@ -14,0 +14,0 @@ const responseBody = await responseClone.text(); |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
293143
2513