Remove old workflow types (#1227)

This commit is contained in:
Shuchang Zheng
2024-11-20 08:23:26 -08:00
committed by GitHub
parent c643472f3c
commit 4271ca9ecf
7 changed files with 17 additions and 79 deletions

View File

@@ -130,78 +130,6 @@ export type ApiKeyApiResponse = {
valid: boolean;
};
export const WorkflowParameterValueType = {
String: "string",
Integer: "integer",
Float: "float",
Boolean: "boolean",
JSON: "json",
FileURL: "file_url",
} as const;
export type WorkflowParameterValueType =
(typeof WorkflowParameterValueType)[keyof typeof WorkflowParameterValueType];
export const WorkflowParameterType = {
Workflow: "workflow",
Context: "context",
Output: "output",
AWS_Secret: "aws_secret",
Bitwarden_Login_Credential: "bitwarden_login_credential",
Bitwarden_Sensitive_Information: "bitwarden_sensitive_information",
} as const;
export type WorkflowParameterType =
(typeof WorkflowParameterType)[keyof typeof WorkflowParameterType];
export type WorkflowParameter = {
key: string;
description: string | null;
workflow_parameter_id: string;
parameter_type: WorkflowParameterType;
workflow_parameter_type: WorkflowParameterValueType;
workflow_id: string;
default_value?: string;
created_at: string | null;
modified_at: string | null;
deleted_at: string | null;
};
export type WorkflowBlock = {
label: string;
block_type: string;
output_parameter?: null;
continue_on_failure: boolean;
url: string;
title: string;
navigation_goal: string;
data_extraction_goal: string;
data_schema: object | null;
error_code_mapping: null; // ?
max_retries: number | null;
max_steps_per_run: number | null;
parameters: []; // ?
};
export type WorkflowApiResponse = {
workflow_id: string;
organization_id: string;
is_saved_task: boolean;
title: string;
workflow_permanent_id: string;
version: number;
description: string;
workflow_definition: {
parameters: Array<WorkflowParameter>;
blocks: Array<WorkflowBlock>;
};
proxy_location: ProxyLocation | null;
webhook_callback_url: string;
created_at: string;
modified_at: string;
deleted_at: string | null;
};
// TODO complete this
export const ActionTypes = {
InputText: "input_text",