Skip to content

Commit

Permalink
[Automatic Import] Migrating to UX design and adding support for gene…
Browse files Browse the repository at this point in the history
…rating auth (elastic#202587)

## Summary

This PR adds authentication to the generated CEL programs, and overhauls
the UI flow to be closer to the forthcoming UX design.

## Details 

This PR provides the following updates related to CEL generation:

1. Adds support for generating auth - basic, oauth2, digest and api
tokens
2. Adds new tooling for working with the OpenAPI specs and support for
reducing the spec to minimally required information to the LLM (new
Kibana dep on [oas](https://www.npmjs.com/package/oas))
3. Addresses various feedback around the generated CEL program (error
handling, cursor, trimming the state.url, etc)
4. Migrates the CEL flow to be closer to the forthcoming design
specified by UX, now within a flyout on the datastream step.
5. Removes the dependency on the CEL generation feature flag

## Current screenshots

<details>
  <summary>Click me</summary>
  
the datastream setup page:
<img width="1724" alt="Screenshot 2024-12-13 at 4 33 28 PM"
src="https://github.com/user-attachments/assets/2d35f448-c5c4-4891-92fc-393f83549213"
/>

the user selects the cel input and the button to configure shows up:
<img width="1725" alt="Screenshot 2024-12-13 at 4 33 49 PM"
src="https://github.com/user-attachments/assets/e55be532-5eaa-4a46-80f1-16dd82430fc4"
/>

upon clicking the button, the flyout opens:
<img width="1722" alt="Screenshot 2024-12-13 at 4 34 02 PM"
src="https://github.com/user-attachments/assets/269248cb-21e7-4ebf-86af-f031facb5822"
/>

the user can upload the spec file (a json or yaml openapi file):
<img width="1722" alt="Screenshot 2024-12-13 at 4 34 30 PM"
src="https://github.com/user-attachments/assets/5f996ff3-194a-416b-a1ae-ba0d5ef89a1a"
/>

the llm will suggest paths to use, or the user can select to enter
manually and view all the GETs
<img width="865" alt="Screenshot 2024-12-13 at 4 35 26 PM"
src="https://github.com/user-attachments/assets/a0ad6d6f-5d82-442a-8f2c-235190b2078c"
/>

we will also suggest an auth method based on the spec, but allow the
user to select otherwise if they want:
<img width="1723" alt="Screenshot 2024-12-13 at 4 35 37 PM"
src="https://github.com/user-attachments/assets/840b0201-cae2-4313-bf5d-d7b3ab2034ed"
/>

if they choose an auth the spec doesn't specify, we will warn but not
block:
<img width="1336" alt="Screenshot 2024-12-16 at 9 07 52 AM"
src="https://github.com/user-attachments/assets/c2fb04b5-3d98-4c70-95b2-2fab259c0702"
/>

once path and auth are selected, they can save and continue (generate
the cel config):
<img width="1722" alt="Screenshot 2024-12-13 at 4 35 50 PM"
src="https://github.com/user-attachments/assets/3e54a435-3ddf-4e64-81ab-49dc25420210"
/>

generating:
<img width="1724" alt="Screenshot 2024-12-13 at 4 36 18 PM"
src="https://github.com/user-attachments/assets/0772c016-078c-44cb-ad72-b096f7d635e2"
/>

all configured:
<img width="1720" alt="Screenshot 2024-12-13 at 4 36 35 PM"
src="https://github.com/user-attachments/assets/5f92979c-1f40-43e3-90f3-941c20c99cc7"
/>

</details>

## Sample results 

> **_Note:_** All these sample integrations are built with the teleport
log samples.

### API key

[eset.json](https://github.com/user-attachments/files/18151638/eset.json)

[eset___api_key-1.0.0.zip](https://github.com/user-attachments/files/18151622/eset___api_key-1.0.0.zip)

### OAuth2

[bitwarden.json](https://github.com/user-attachments/files/18151635/bitwarden.json)

[bitwarden___oauth-1.0.0.zip](https://github.com/user-attachments/files/18151618/bitwarden___oauth-1.0.0.zip)

### Basic 

[sumlogic-api.yaml.zip](https://github.com/user-attachments/files/18151650/sumlogic-api.yaml.zip)

[sumologic___basic-1.0.0.zip](https://github.com/user-attachments/files/18151630/sumologic___basic-1.0.0.zip)

Relates:
- elastic#197651
- elastic#197653

---------

Co-authored-by: kibanamachine <[email protected]>
Co-authored-by: Ilya Nikokoshev <[email protected]>
  • Loading branch information
3 people authored Jan 10, 2025
1 parent baf79bc commit 0585712
Show file tree
Hide file tree
Showing 106 changed files with 5,238 additions and 1,094 deletions.
2 changes: 2 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -1173,6 +1173,7 @@
"json-stable-stringify": "^1.0.1",
"json-stringify-pretty-compact": "1.2.0",
"json-stringify-safe": "5.0.1",
"jsonpath-plus": "^10.2.0",
"jsonwebtoken": "^9.0.2",
"jsts": "^1.6.2",
"kea": "^2.6.0",
Expand Down Expand Up @@ -1204,6 +1205,7 @@
"nodemailer": "^6.9.15",
"normalize-path": "^3.0.0",
"nunjucks": "^3.2.4",
"oas": "^25.2.0",
"object-hash": "^1.3.1",
"object-path-immutable": "^3.1.1",
"openai": "^4.72.0",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23845,7 +23845,6 @@
"xpack.ingestPipelines.testPipelineFlyout.successNotificationText": "Pipeline exécuté",
"xpack.ingestPipelines.testPipelineFlyout.title": "Pipeline de test",
"xpack.integrationAssistant.bottomBar.addToElastic": "Ajouter à Elastic",
"xpack.integrationAssistant.bottomBar.analyzeCel": "Générer la configuration d'entrée CEL",
"xpack.integrationAssistant.bottomBar.analyzeLogs": "Analyser les logs",
"xpack.integrationAssistant.bottomBar.close": "Fermer",
"xpack.integrationAssistant.bottomBar.loading": "Chargement",
Expand Down Expand Up @@ -23901,17 +23900,6 @@
"xpack.integrationAssistant.missingPrivileges.title": "Privilèges manquants",
"xpack.integrationAssistant.pages.header.avatarTitle": "Alimenté par l’IA générative",
"xpack.integrationAssistant.pages.header.title": "Nouvelle intégration",
"xpack.integrationAssistant.step.celInput.apiDefinition.description": "Glissez et déposez un fichier ou parcourez les fichiers.",
"xpack.integrationAssistant.step.celInput.apiDefinition.description2": "Spécifications relatives à OpenAPI",
"xpack.integrationAssistant.step.celInput.apiDefinition.label": "Spéc. relatives à OpenAPI",
"xpack.integrationAssistant.step.celInput.celInputDescription": "Chargez un fichier de spécifications OpenAPI pour générer une configuration pour l'entrée CEL",
"xpack.integrationAssistant.step.celInput.celInputTitle": "Générer la configuration d'entrée CEL",
"xpack.integrationAssistant.step.celInput.generationError": "Une erreur s'est produite durant : Génération d'entrée CEL",
"xpack.integrationAssistant.step.celInput.openapiSpec.errorCanNotRead": "Impossible de lire le fichier de logs exemple",
"xpack.integrationAssistant.step.celInput.openapiSpec.errorCanNotReadWithReason": "Une erreur s'est produite lors de la lecture du fichier de spécifications : {reason}",
"xpack.integrationAssistant.step.celInput.openapiSpec.errorTooLargeToParse": "Ce fichier de spécifications est trop volumineux pour être analysé",
"xpack.integrationAssistant.step.celInput.progress.relatedGraph": "Génération de la configuration d'entrée CEL",
"xpack.integrationAssistant.step.celInput.retryButtonLabel": "Réessayer",
"xpack.integrationAssistant.step.connector": "Connecteur",
"xpack.integrationAssistant.step.dataStream": "Flux de données",
"xpack.integrationAssistant.step.dataStream.analyzing": "Analyse",
Expand Down Expand Up @@ -23963,12 +23951,6 @@
"xpack.integrationAssistant.step.review.ingestPipelineTitle": "Pipeline d'ingestion",
"xpack.integrationAssistant.step.review.save": "Enregistrer",
"xpack.integrationAssistant.step.review.title": "Examiner les résultats",
"xpack.integrationAssistant.step.reviewCel.description": "Vérifiez les paramètres de configuration d'entrée CEL générés pour votre intégration. Ces paramètres seront automatiquement renseignés dans la configuration d'intégration où la modification sera possible.",
"xpack.integrationAssistant.step.reviewCel.program": "Le programme CEL à exécuter pour chaque sondage",
"xpack.integrationAssistant.step.reviewCel.redact": "Champs à adapter",
"xpack.integrationAssistant.step.reviewCel.save": "Enregistrer",
"xpack.integrationAssistant.step.reviewCel.state": "État initial de l'évaluation du CEL",
"xpack.integrationAssistant.step.reviewCel.title": "Examiner les résultats",
"xpack.integrationAssistant.steps.connector.createConnectorLabel": "Créer un nouveau connecteur",
"xpack.integrationAssistant.steps.connector.description": "Sélectionnez un connecteur d’IA pour vous aider à créer votre intégration personnalisée",
"xpack.integrationAssistant.steps.connector.supportedModelsInfo": "Pour une expérience optimale, nous recommandons actuellement d'utiliser un fournisseur prenant en charge les nouveaux modèles Claude. Nous travaillons actuellement à l'ajout d'une meilleure prise en charge de GPT-4 et de modèles similaires",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23706,7 +23706,6 @@
"xpack.ingestPipelines.testPipelineFlyout.successNotificationText": "パイプラインが実行されました",
"xpack.ingestPipelines.testPipelineFlyout.title": "パイプラインをテスト",
"xpack.integrationAssistant.bottomBar.addToElastic": "Elasticに追加",
"xpack.integrationAssistant.bottomBar.analyzeCel": "CEL入力構成を生成",
"xpack.integrationAssistant.bottomBar.analyzeLogs": "ログを分析",
"xpack.integrationAssistant.bottomBar.close": "閉じる",
"xpack.integrationAssistant.bottomBar.loading": "読み込み中",
Expand Down Expand Up @@ -23762,17 +23761,6 @@
"xpack.integrationAssistant.missingPrivileges.title": "不足している権限",
"xpack.integrationAssistant.pages.header.avatarTitle": "生成AIを活用",
"xpack.integrationAssistant.pages.header.title": "新しい統合",
"xpack.integrationAssistant.step.celInput.apiDefinition.description": "ファイルをドラッグアンドドロップするか、ファイルを参照します。",
"xpack.integrationAssistant.step.celInput.apiDefinition.description2": "OpenAPI仕様",
"xpack.integrationAssistant.step.celInput.apiDefinition.label": "OpenAPI仕様",
"xpack.integrationAssistant.step.celInput.celInputDescription": "OpenAPI仕様ファイルをアップロードして、CEL入力の構成を生成",
"xpack.integrationAssistant.step.celInput.celInputTitle": "CEL入力構成を生成",
"xpack.integrationAssistant.step.celInput.generationError": "エラーが発生しました:CEL入力生成",
"xpack.integrationAssistant.step.celInput.openapiSpec.errorCanNotRead": "ログサンプルファイルを読み取れませんでした",
"xpack.integrationAssistant.step.celInput.openapiSpec.errorCanNotReadWithReason": "仕様ファイルの読み取り中にエラーが発生しました:{reason}",
"xpack.integrationAssistant.step.celInput.openapiSpec.errorTooLargeToParse": "この仕様ファイルは大きすぎて解析できません",
"xpack.integrationAssistant.step.celInput.progress.relatedGraph": "CEL入力構成を生成中",
"xpack.integrationAssistant.step.celInput.retryButtonLabel": "再試行",
"xpack.integrationAssistant.step.connector": "コネクター",
"xpack.integrationAssistant.step.dataStream": "データストリーム",
"xpack.integrationAssistant.step.dataStream.analyzing": "分析中",
Expand Down Expand Up @@ -23824,12 +23812,6 @@
"xpack.integrationAssistant.step.review.ingestPipelineTitle": "パイプラインを投入",
"xpack.integrationAssistant.step.review.save": "保存",
"xpack.integrationAssistant.step.review.title": "結果を確認",
"xpack.integrationAssistant.step.reviewCel.description": "統合の生成されたCEL入力構成設定を確認してください。これらの設定は、編集が可能な場合、統合構成に自動的に入力されます。",
"xpack.integrationAssistant.step.reviewCel.program": "各ポーリングで実行されるCELプログラム",
"xpack.integrationAssistant.step.reviewCel.redact": "改訂されたフィールド",
"xpack.integrationAssistant.step.reviewCel.save": "保存",
"xpack.integrationAssistant.step.reviewCel.state": "初期CEL評価状態",
"xpack.integrationAssistant.step.reviewCel.title": "結果を確認",
"xpack.integrationAssistant.steps.connector.createConnectorLabel": "新しいコネクターを作成",
"xpack.integrationAssistant.steps.connector.description": "カスタム統合の作成を支援するAIコネクターを選択",
"xpack.integrationAssistant.steps.connector.supportedModelsInfo": "現在、最高のエクスペリエンスが得られるように、新しいClaudeモデルをサポートするプロバイダーを利用することをお勧めします。現在、GPT-4や類似モデルへの改善されたサポートの追加に取り組んでいます。",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23297,7 +23297,6 @@
"xpack.ingestPipelines.testPipelineFlyout.successNotificationText": "管道已执行",
"xpack.ingestPipelines.testPipelineFlyout.title": "测试管道",
"xpack.integrationAssistant.bottomBar.addToElastic": "添加到 Elastic",
"xpack.integrationAssistant.bottomBar.analyzeCel": "生成 CEL 输入配置",
"xpack.integrationAssistant.bottomBar.analyzeLogs": "分析日志",
"xpack.integrationAssistant.bottomBar.close": "关闭",
"xpack.integrationAssistant.bottomBar.loading": "正在加载",
Expand Down Expand Up @@ -23353,17 +23352,6 @@
"xpack.integrationAssistant.missingPrivileges.title": "缺少权限",
"xpack.integrationAssistant.pages.header.avatarTitle": "由生成式 AI 提供支持",
"xpack.integrationAssistant.pages.header.title": "新集成",
"xpack.integrationAssistant.step.celInput.apiDefinition.description": "拖放文件或浏览文件。",
"xpack.integrationAssistant.step.celInput.apiDefinition.description2": "OpenAPI 规范",
"xpack.integrationAssistant.step.celInput.apiDefinition.label": "OpenAPI 规范",
"xpack.integrationAssistant.step.celInput.celInputDescription": "上传 OpenAPI 规范文件以为 CEL 输入生成配置",
"xpack.integrationAssistant.step.celInput.celInputTitle": "生成 CEL 输入配置",
"xpack.integrationAssistant.step.celInput.generationError": "以下期间发生错误:CEL 输入生成",
"xpack.integrationAssistant.step.celInput.openapiSpec.errorCanNotRead": "无法读取日志样例文件",
"xpack.integrationAssistant.step.celInput.openapiSpec.errorCanNotReadWithReason": "读取规范文件时发生错误:{reason}",
"xpack.integrationAssistant.step.celInput.openapiSpec.errorTooLargeToParse": "此规范文件太大,无法解析",
"xpack.integrationAssistant.step.celInput.progress.relatedGraph": "正在生成 CEL 输入配置",
"xpack.integrationAssistant.step.celInput.retryButtonLabel": "重试",
"xpack.integrationAssistant.step.connector": "连接器",
"xpack.integrationAssistant.step.dataStream": "数据流",
"xpack.integrationAssistant.step.dataStream.analyzing": "正在分析",
Expand Down Expand Up @@ -23415,12 +23403,6 @@
"xpack.integrationAssistant.step.review.ingestPipelineTitle": "采集管道",
"xpack.integrationAssistant.step.review.save": "保存",
"xpack.integrationAssistant.step.review.title": "复查结果",
"xpack.integrationAssistant.step.reviewCel.description": "查看为您的集成生成的 CEL 输入配置设置。在可以进行编辑的情况下,会将这些设置自动填充到集成配置中。",
"xpack.integrationAssistant.step.reviewCel.program": "要为每次轮询运行的 CEL 程序",
"xpack.integrationAssistant.step.reviewCel.redact": "已编辑字段",
"xpack.integrationAssistant.step.reviewCel.save": "保存",
"xpack.integrationAssistant.step.reviewCel.state": "初始 CEL 评估状态",
"xpack.integrationAssistant.step.reviewCel.title": "复查结果",
"xpack.integrationAssistant.steps.connector.createConnectorLabel": "创建新连接器",
"xpack.integrationAssistant.steps.connector.description": "选择 AI 连接器以帮助您创建定制集成",
"xpack.integrationAssistant.steps.connector.supportedModelsInfo": "当前,我们建议使用支持更新 Claude 模型的提供商,以获得最佳体验。目前,我们正努力为 GPT-4 和类似模型添加更全面的支持",
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
/*
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
* or more contributor license agreements. Licensed under the Elastic License
* 2.0; you may not use this file except in compliance with the Elastic License
* 2.0.
*/

import { ApiAnalysisState } from '../../server/types';

export const apiAnalysisTestState: ApiAnalysisState = {
dataStreamName: 'testDataStream',
lastExecutedChain: 'testchain',
results: { test: 'testResults' },
pathOptions: { '/path1': 'path1 description', '/path2': 'path2 description' },
suggestedPaths: ['/path1'],
};

export const apiAnalysisPathSuggestionsMockedResponse = ['/path1', '/path2', '/path3', '/path4'];

export const apiAnalysisExpectedResults = {
suggestedPaths: ['/path1', '/path2', '/path3', '/path4'],
};
Original file line number Diff line number Diff line change
Expand Up @@ -5,18 +5,25 @@
* 2.0.
*/

export const celTestState = {
import { CelInputState } from '../../server/types';

export const celTestState: CelInputState = {
dataStreamName: 'testDataStream',
apiDefinition: 'apiDefinition',
lastExecutedChain: 'testchain',
finalized: false,
apiQuerySummary: 'testQuerySummary',
exampleCelPrograms: [],
currentProgram: 'testProgram',
stateVarNames: ['testVar'],
stateSettings: { test: 'testDetails' },
configFields: { test: { config1: 'config1testDetails' } },
redactVars: ['testRedact'],
results: { test: 'testResults' },
path: './testPath',
authType: 'basic',
openApiPathDetails: {},
openApiSchemas: {},
openApiAuthSchema: {},
hasProgramHeaders: false,
};

export const celQuerySummaryMockedResponse = `To cover all events in a chronological manner for the device_tasks endpoint, you should use the /v1/device_tasks GET route with pagination parameters. Specifically, use the pageSize and pageToken query parameters. Start with a large pageSize and use the nextPageToken from each response to fetch subsequent pages until all events are retrieved.
Expand Down Expand Up @@ -83,16 +90,25 @@ export const celStateDetailsMockedResponse = [
name: 'config1',
default: 50,
redact: false,
configurable: true,
description: 'config1 description',
type: 'number',
},
{
name: 'config2',
default: '',
redact: true,
configurable: false,
description: 'config2 description',
type: 'string',
},
{
name: 'config3',
default: 'event',
redact: false,
configurable: false,
description: 'config3 description',
type: 'string',
},
];

Expand All @@ -102,6 +118,14 @@ export const celStateSettings = {
config3: 'event',
};

export const celConfigFields = {
config1: {
default: 50,
type: 'number',
description: 'config1 description',
},
};

export const celRedact = ['config2'];

export const celExpectedResults = {
Expand All @@ -111,5 +135,13 @@ export const celExpectedResults = {
config2: '',
config3: 'event',
},
configFields: {
config1: {
default: 50,
type: 'number',
description: 'config1 description',
},
},
needsAuthConfigBlock: false,
redactVars: ['config2'],
};
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* 2.0; you may not use this file except in compliance with the Elastic License
* 2.0.
*/
import type { Pipeline } from '../../common';
import type { CelAuthType, Pipeline } from '../../common';
const currentPipelineMock: Pipeline = {
description: 'Pipeline to process mysql_enterprise audit logs',
processors: [
Expand Down Expand Up @@ -53,7 +53,16 @@ export const mockedRequestWithPipeline = {
currentPipeline: currentPipelineMock,
};

export const mockedRequestWithApiDefinition = {
apiDefinition: '{ "openapi": "3.0.0" }',
export const mockedRequestWithCelDetails = {
dataStreamTitle: 'audit',
path: '/events',
authType: 'basic' as CelAuthType,
openApiDetails: {},
openApiSchema: {},
openApiAuthSchema: {},
};

export const mockedApiAnalysisRequest = {
dataStreamName: 'audit',
pathOptions: { '/path1': 'path1 description' },
};
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
/*
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
* or more contributor license agreements. Licensed under the Elastic License
* 2.0; you may not use this file except in compliance with the Elastic License
* 2.0.
*/

/*
* NOTICE: Do not edit this file manually.
* This file is automatically generated by the OpenAPI Generator, @kbn/openapi-generator.
*
* info:
* title: Automatic Import Analyze API specifications API endpoint
* version: 1
*/

import { z } from '@kbn/zod';

import { DataStreamTitle, Connector, LangSmithOptions } from '../model/common_attributes.gen';
import { PathOptions } from '../model/cel_input_attributes.gen';
import { AnalyzeApiAPIResponse } from '../model/response_schemas.gen';

export type AnalyzeApiRequestBody = z.infer<typeof AnalyzeApiRequestBody>;
export const AnalyzeApiRequestBody = z.object({
dataStreamTitle: DataStreamTitle,
pathOptions: PathOptions,
connectorId: Connector,
langSmithOptions: LangSmithOptions.optional(),
});
export type AnalyzeApiRequestBodyInput = z.input<typeof AnalyzeApiRequestBody>;

export type AnalyzeApiResponse = z.infer<typeof AnalyzeApiResponse>;
export const AnalyzeApiResponse = AnalyzeApiAPIResponse;
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
openapi: 3.0.3
info:
title: Automatic Import Analyze API specifications API endpoint
version: "1"
paths:
/internal/automatic_import/analyzeapi:
post:
summary: Analyzes API specifications.
operationId: AnalyzeApi
x-codegen-enabled: true
description: Analyzes API specifications.
tags:
- Analyze API spec
requestBody:
required: true
content:
application/json:
schema:
type: object
required:
- dataStreamTitle
- pathOptions
- connectorId
properties:
dataStreamTitle:
$ref: "../model/common_attributes.schema.yaml#/components/schemas/DataStreamTitle"
pathOptions:
$ref: "../model/cel_input_attributes.schema.yaml#/components/schemas/PathOptions"
connectorId:
$ref: "../model/common_attributes.schema.yaml#/components/schemas/Connector"
langSmithOptions:
$ref: "../model/common_attributes.schema.yaml#/components/schemas/LangSmithOptions"
responses:
200:
description: Indicates a successful call.
content:
application/json:
schema:
$ref: "../model/response_schemas.schema.yaml#/components/schemas/AnalyzeApiAPIResponse"
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
/*
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
* or more contributor license agreements. Licensed under the Elastic License
* 2.0; you may not use this file except in compliance with the Elastic License
* 2.0.
*/

import { expectParseSuccess } from '@kbn/zod-helpers';
import { AnalyzeApiRequestBody } from './analyze_api_route.gen';
import { getAnalyzeApiRequestBody } from '../model/api_test.mock';

describe('Analyze API request schema', () => {
test('full request validate', () => {
const payload: AnalyzeApiRequestBody = getAnalyzeApiRequestBody();

const result = AnalyzeApiRequestBody.safeParse(payload);
expectParseSuccess(result);
expect(result.data).toEqual(payload);
});
});
Original file line number Diff line number Diff line change
Expand Up @@ -16,14 +16,14 @@

import { z } from '@kbn/zod';

import { DataStreamName, Connector, LangSmithOptions } from '../model/common_attributes.gen';
import { ApiDefinition } from '../model/cel_input_attributes.gen';
import { DataStreamTitle, Connector, LangSmithOptions } from '../model/common_attributes.gen';
import { CelDetails } from '../model/cel_input_attributes.gen';
import { CelInputAPIResponse } from '../model/response_schemas.gen';

export type CelInputRequestBody = z.infer<typeof CelInputRequestBody>;
export const CelInputRequestBody = z.object({
dataStreamName: DataStreamName,
apiDefinition: ApiDefinition,
dataStreamTitle: DataStreamTitle,
celDetails: CelDetails,
connectorId: Connector,
langSmithOptions: LangSmithOptions.optional(),
});
Expand Down
Loading

0 comments on commit 0585712

Please sign in to comment.