refactor: IDL structure modification (#475)

This commit is contained in:
liuyunchao-1998
2025-08-07 15:59:51 +08:00
committed by GitHub
parent b25bf6728a
commit e7d25319ff
221 changed files with 8289 additions and 17471 deletions

View File

@@ -1,26 +1,19 @@
include "./plugin/plugin_develop.thrift"
include "./flow/marketplace/flow_marketplace_product/public_api.thrift"
include "./data_engine/dataset/dataset.thrift"
include "./data_engine/dataset/flow_dataengine_dataset.thrift"
include "./data_engine/dataset/document.thrift"
include "./data_engine/dataset/slice.thrift"
include "./bot_platform/ocean_cloud_workflow/workflow.thrift"
include "./bot_platform/ocean_cloud_workflow/trace.thrift"
include "./flow/devops/debugger/flow.devops.debugger.coze.thrift"
include "./intelligence/intelligence.thrift"
include "./developer/developer_api.thrift"
include "./marketplace/public_api.thrift"
include "./data/knowledge/knowledge_svc.thrift"
include "./app/intelligence.thrift"
include "./app/developer_api.thrift"
include "./playground/playground.thrift"
include "./data_engine/ocean_cloud_memory/table/table.thrift"
include "./memory/database.thrift"
include "./data/database/database_svc.thrift"
include "./permission/openapiauth_service.thrift"
include "./conversation/conversation_service.thrift"
include "./conversation/message_service.thrift"
include "./conversation/agentrun_service.thrift"
include "./data_engine/ocean_cloud_memory/ocean_cloud_memory.thrift"
include "./data/variable/variable_svc.thrift"
include "./resource/resource.thrift"
include "./passport/passport.thrift"
include "./bot_platform/ocean_cloud_workflow/ocean_cloud_workflow.thrift"
include "./bot_open_api/bot_open_api.thrift"
include "./workflow/workflow_svc.thrift"
include "./app/bot_open_api.thrift"
include "./upload/upload.thrift"
@@ -31,15 +24,15 @@ service ConversationService extends conversation_service.ConversationService {}
service MessageService extends message_service.MessageService {}
service AgentRunService extends agentrun_service.AgentRunService {}
service OpenAPIAuthService extends openapiauth_service.OpenAPIAuthService {}
service MemoryService extends ocean_cloud_memory.MemoryService {}
service MemoryService extends variable_svc.MemoryService {}
service PluginDevelopService extends plugin_develop.PluginDevelopService {}
service PublicProductService extends public_api.PublicProductService {}
service DeveloperApiService extends developer_api.DeveloperApiService {}
service PlaygroundService extends playground.PlaygroundService {}
service DatabaseService extends database.DatabaseService {}
service DatabaseService extends database_svc.DatabaseService {}
service ResourceService extends resource.ResourceService {}
service PassportService extends passport.PassportService {}
service WorkflowService extends ocean_cloud_workflow.WorkflowService {}
service KnowledgeService extends flow_dataengine_dataset.DatasetService {}
service WorkflowService extends workflow_svc.WorkflowService {}
service KnowledgeService extends knowledge_svc.DatasetService {}
service BotOpenApiService extends bot_open_api.BotOpenApiService {}
service UploadService extends upload.UploadService {}

View File

@@ -1,4 +1,4 @@
namespace go ocean.cloud.bot_common
namespace go app.bot_common
struct AuthToken {

View File

@@ -0,0 +1,56 @@
namespace go app.bot_open_api
include "../base.thrift"
include "bot_common.thrift"
struct OauthAuthorizationCodeReq {
1: string code (api.query='code') ,
2: string state (api.query='state'),
}
struct OauthAuthorizationCodeResp {
255: required base.BaseResp BaseResp,
}
struct GetBotOnlineInfoReq {
1 : required i64 bot_id (api.js_conv="true") // botId
2: optional string connector_id // Keep it first, don't expose it, and don't use the field
3 : optional string version // bot version, get the latest version if you don't pass it on.
}
struct UploadFileOpenRequest {
1: required string ContentType (api.header = "Content-Type", agw.source = "header", agw.key = "Content-Type"), // file type
2: required binary Data (api.raw_body = ""), // binary data
255: base.Base Base
}
struct UploadFileOpenResponse {
1: optional File File (api.body = "data")
253: required i64 code
254: required string msg
255: base.BaseResp BaseResp
}
struct File{
1: string URI (api.body = "uri"), // 文件URI
2: i64 Bytes (api.body = "bytes"), // 文件字节数
3: i64 CreatedAt (agw.key = "created_at"), // 上传时间戳单位s
4: string FileName (api.body = "file_name"), // 文件名
5: string URL (api.body = "url")
}
// resp
struct GetBotOnlineInfoResp {
1: required i32 code
2: required string msg
3: required bot_common.OpenAPIBotInfo data
}
service BotOpenApiService {
OauthAuthorizationCodeResp OauthAuthorizationCode(1: OauthAuthorizationCodeReq request)(api.get='/api/oauth/authorization_code', api.category="oauth", api.gen_path="oauth")
//openapi
GetBotOnlineInfoResp GetBotOnlineInfo(1: GetBotOnlineInfoReq request)(api.get='/v1/bot/get_online_info', api.category="bot", api.tag="openapi", api.gen_path="personal_api")
// File related OpenAPI
UploadFileOpenResponse UploadFileOpen(1: UploadFileOpenRequest request)(api.post = "/v1/files/upload", api.category="file", api.tag="openapi", agw.preserve_base="true")
}

View File

@@ -1,4 +1,4 @@
namespace go intelligence.common
namespace go app.intelligence.common
struct UserLabel {
1: string label_id ,

View File

@@ -1,4 +1,4 @@
namespace go intelligence.common
namespace go app.intelligence.common
enum IntelligenceStatus {
Using = 1,

View File

@@ -1,3 +1,5 @@
namespace go app.intelligence.common
struct ProjectInnerTaskInfo {
1: i64 task_id (agw.js_conv="str",api.js_conv="true") // Task ID
}

View File

@@ -1,8 +1,8 @@
include "../base.thrift"
include "../bot_common/bot_common.thrift"
include "bot_common.thrift"
include "../playground/shortcut_command.thrift"
namespace go ocean.cloud.developer_api
namespace go app.developer_api
struct DraftBotCreateRequest {

View File

@@ -2,11 +2,11 @@ include "../base.thrift"
include "search.thrift"
include "common_struct/intelligence_common_struct.thrift"
include "common_struct/common_struct.thrift"
include "./project.thrift"
include "project.thrift"
include "publish.thrift"
include "task.thrift"
namespace go intelligence
namespace go app.intelligence
service IntelligenceService {
project.DraftProjectCreateResponse DraftProjectCreate(1: project.DraftProjectCreateRequest request)(api.post='/api/intelligence_api/draft_project/create', api.category="draft_project",agw.preserve_base="true")

View File

@@ -1,3 +1,4 @@
namespace go app.intelligence.project
include "../base.thrift"
include "common_struct/intelligence_common_struct.thrift"
include "common_struct/common_struct.thrift"

View File

@@ -1,3 +1,4 @@
namespace go app.intelligence.publish
include "../base.thrift"
include "common_struct/common_struct.thrift"
include "common_struct/intelligence_common_struct.thrift"

View File

@@ -1,9 +1,8 @@
namespace go app.intelligence
include "../base.thrift"
include "common_struct/intelligence_common_struct.thrift"
include "common_struct/common_struct.thrift"
namespace go intelligence
enum OrderBy {
UpdateTime = 0
CreateTime = 1

View File

@@ -1,3 +1,4 @@
namespace go app.intelligence.task
include "../base.thrift"
include "common_struct/task_struct.thrift"

View File

@@ -1,15 +0,0 @@
include "../base.thrift"
namespace go ocean.cloud.bot_open_api
struct OauthAuthorizationCodeReq {
1: string code (api.query='code') ,
2: string state (api.query='state'),
}
struct OauthAuthorizationCodeResp {
255: required base.BaseResp BaseResp,
}
service BotOpenApiService {
OauthAuthorizationCodeResp OauthAuthorizationCode(1: OauthAuthorizationCodeReq request)(api.get='/api/oauth/authorization_code', api.category="oauth", api.gen_path="oauth")
}

View File

@@ -1,7 +1,7 @@
include "../data_engine/ocean_cloud_memory/table/table.thrift"
include "../data_engine/ocean_cloud_memory/knowledge/kdocument.thrift"
include "table.thrift"
include "../knowledge/document.thrift"
namespace go database
namespace go data.database
service DatabaseService {
table.ListDatabaseResponse ListDatabase(1: table.ListDatabaseRequest req)(api.post='/api/memory/database/list', api.category="memory",agw.preserve_base="true")
@@ -19,7 +19,7 @@ service DatabaseService {
table.GetSpaceConnectorListResponse GetConnectorName(1:table.GetSpaceConnectorListRequest req)(api.post='/api/memory/database/get_connector_name', api.category="memory",agw.preserve_base="true")
table.GetBotTableResponse GetBotDatabase(1: table.GetBotTableRequest req)(api.post='/api/memory/database/table/list_new', api.category="memory",agw.preserve_base="true")
table.UpdateDatabaseBotSwitchResponse UpdateDatabaseBotSwitch(1:table.UpdateDatabaseBotSwitchRequest req)(api.post='/api/memory/database/update_bot_switch', api.category="memory",agw.preserve_base="true")
kdocument.GetTableSchemaInfoResponse GetDatabaseTableSchema(1:table.GetTableSchemaRequest req)(api.post='/api/memory/table_schema/get', api.category="memory",agw.preserve_base="true")
document.GetTableSchemaInfoResponse GetDatabaseTableSchema(1:table.GetTableSchemaRequest req)(api.post='/api/memory/table_schema/get', api.category="memory",agw.preserve_base="true")
table.ValidateTableSchemaResponse ValidateDatabaseTableSchema(1:table.ValidateTableSchemaRequest req)(api.post='/api/memory/table_schema/validate', api.category="memory",agw.preserve_base="true")
table.SubmitDatabaseInsertResponse SubmitDatabaseInsertTask(1:table.SubmitDatabaseInsertRequest req)(api.post='/api/memory/table_file/submit', api.category="memory",agw.preserve_base="true")
table.GetDatabaseFileProgressResponse DatabaseFileProgressData(1:table.GetDatabaseFileProgressRequest req)(api.post='/api/memory/table_file/get_progress', api.category="memory",agw.preserve_base="true")

View File

@@ -1,5 +1,5 @@
include "../../../base.thrift"
include "../../base.thrift"
namespace go data.database.table
enum RefType {
NoRef = 0
Bot = 1
@@ -362,27 +362,6 @@ struct GetNL2SQLResponse {
255: optional base.BaseResp BaseResp
}
struct GetModeConfigRequest {
1: required i64 bot_id // bot id
2: optional i64 connector_id // line of business id
3: optional string connector_uid // line of business user id
255: optional base.Base Base
}
struct GetModeConfigResponse {
1: i32 code
2: string msg
3: string mode
4: i64 bot_id
5: i64 max_table_num
6: i64 max_column_num
7: i64 max_capacity_kb
8: i64 max_row_num
255: optional base.BaseResp BaseResp
}
struct ResetBotTableRequest {
1: optional i64 creator_id (api.js_conv="str", api.key="creator_id")
2: optional i64 bot_id (api.js_conv="str", api.key="bot_id")
@@ -770,12 +749,6 @@ enum TableDataType {
OnlyPreview = 2 // Just preview the data
}
struct DocTableSheet {
1: i64 id; // Number of sheet
2: string sheet_name; // Sheet name
3: i64 total_row; // total number of rows
}
struct TableColumn {
1: i64 id(api.js_conv="str", api.key="id") // Column ID
2: string column_name // column_name

View File

@@ -1,4 +1,4 @@
namespace go flow.dataengine.dataset
namespace go data.knowledge
// type
enum FormatType {
@@ -95,4 +95,25 @@ enum ReviewStatus {
Enable = 1 // Completed.
Failed = 2 // fail
ForceStop = 3 // fail
}
// Table column information
struct DocTableColumn {
1: i64 id(agw.js_conv="str", api.js_conv="true", api.body="id"); // Column ID
2: string column_name; // column_name
3: bool is_semantic; // Is it a semantically matched column?
4: i64 sequence(agw.js_conv="str", api.js_conv="true", api.body="sequence"); // List the serial number originally in excel
5: optional ColumnType column_type; // column type
6: optional bool contains_empty_value
7: optional string desc; // describe
}
enum ColumnType {
Unknown = 0
Text = 1 // Text
Number = 2 // number
Date = 3 // time
Float = 4 // float
Boolean = 5 // bool
Image = 6 // picture
}

View File

@@ -1,7 +1,7 @@
include "../../base.thrift"
include "common.thrift"
namespace go flow.dataengine.dataset
namespace go data.knowledge
struct ListDocumentRequest {
1: required i64 dataset_id(agw.js_conv='str', api.js_conv='true')
@@ -60,22 +60,11 @@ struct TableColumn {
2: string column_name // column_name
3: bool is_semantic // Is it a semantically matched column?
4: i64 sequence(agw.js_conv="str", api.js_conv="true", api.body="sequence")// List the serial number originally in excel
5: optional ColumnType column_type // column type
5: optional common.ColumnType column_type // column type
6: optional bool contains_empty_value
7: optional string desc // describe
}
enum ColumnType {
Unknown = 0
Text = 1 // Text
Number = 2 // number
Date = 3 // time
Float = 4 // float
Boolean = 5 // bool
Image = 6 // picture
}
struct DeleteDocumentRequest {
2: list<string> document_ids // List of document IDs to delete
@@ -335,3 +324,30 @@ struct ExtractPhotoCaptionResponse {
254: required string msg
255: required base.BaseResp BaseResp(api.none="true")
}
struct GetDocumentTableInfoRequest {
2: optional string tos_uri; // If the table is uploaded for the first local file, pass the value
3: optional i64 document_id(agw.js_conv="str", api.js_conv="true", api.body="document_id"); // If it is a document with an existing table, pass the value
4: i64 creator_id; // Creator [http interface does not need to be passed]
255: optional base.Base Base
}
struct GetDocumentTableInfoResponse {
1: i32 code
2: string msg
3: list<DocTableSheet> sheet_list
4: map<string, list<common.DocTableColumn>> table_meta(api.body="table_meta") // key: sheet_id -> list<common.DocTableColumn>
5: map<string, list<map<string,string>>> preview_data(api.body="preview_data") // key: sheet_id -> list_preview_data
255: required base.BaseResp BaseResp(api.none="true")
}
struct GetTableSchemaInfoResponse {
1: i32 code
2: string msg
3: list<DocTableSheet> sheet_list
4: list<common.DocTableColumn> table_meta // The schema of the selected sheet, not selected to return the first sheet by default
5: list<map<i64,string>> preview_data(agw.js_conv="str", agw.key="preview_data") // The knowledge table will return
255: optional base.BaseResp BaseResp(api.none="true")
}

View File

@@ -2,7 +2,7 @@ include "../../base.thrift"
include "common.thrift"
namespace go flow.dataengine.dataset
namespace go data.knowledge
struct CreateDatasetRequest {
1: string name // Knowledge base name, no more than 100 characters in length
@@ -160,5 +160,26 @@ struct GetIconResponse {
253: required i64 code
254: required string msg
255: optional base.BaseResp BaseResp
}
struct GetModeConfigRequest {
1: required i64 bot_id // bot id
2: optional i64 connector_id // line of business id
3: optional string connector_uid // line of business user id
255: optional base.Base Base
}
struct GetModeConfigResponse {
1: i32 code
2: string msg
3: string mode
4: i64 bot_id
5: i64 max_table_num
6: i64 max_column_num
7: i64 max_capacity_kb
8: i64 max_row_num
255: optional base.BaseResp BaseResp
}

View File

@@ -1,19 +1,20 @@
include "slice.thrift"
include "dataset.thrift"
include "knowledge.thrift"
include "document.thrift"
include "common.thrift"
include "review.thrift"
namespace go flow.dataengine.dataset
namespace go data.knowledge
service DatasetService {
// Knowledge base related
dataset.GetIconResponse GetIconForDataset(1:dataset.GetIconRequest req) (api.post='/api/knowledge/icon/get', api.category="knowledge",agw.preserve_base="true")
dataset.CreateDatasetResponse CreateDataset(1:dataset.CreateDatasetRequest req) (api.post='/api/knowledge/create', api.category="knowledge",agw.preserve_base="true")
dataset.DatasetDetailResponse DatasetDetail(1:dataset.DatasetDetailRequest req) (api.post='/api/knowledge/detail', api.category="knowledge",agw.preserve_base="true")
dataset.ListDatasetResponse ListDataset(1:dataset.ListDatasetRequest req) (api.post='/api/knowledge/list', api.category="knowledge",agw.preserve_base="true")
dataset.DeleteDatasetResponse DeleteDataset(1:dataset.DeleteDatasetRequest req) (api.post='/api/knowledge/delete', api.category="knowledge",agw.preserve_base="true")
dataset.UpdateDatasetResponse UpdateDataset(1:dataset.UpdateDatasetRequest req) (api.post='/api/knowledge/update', api.category="knowledge",agw.preserve_base="true")
knowledge.GetIconResponse GetIconForDataset(1:knowledge.GetIconRequest req) (api.post='/api/knowledge/icon/get', api.category="knowledge",agw.preserve_base="true")
knowledge.CreateDatasetResponse CreateDataset(1:knowledge.CreateDatasetRequest req) (api.post='/api/knowledge/create', api.category="knowledge",agw.preserve_base="true")
knowledge.DatasetDetailResponse DatasetDetail(1:knowledge.DatasetDetailRequest req) (api.post='/api/knowledge/detail', api.category="knowledge",agw.preserve_base="true")
knowledge.ListDatasetResponse ListDataset(1:knowledge.ListDatasetRequest req) (api.post='/api/knowledge/list', api.category="knowledge",agw.preserve_base="true")
knowledge.DeleteDatasetResponse DeleteDataset(1:knowledge.DeleteDatasetRequest req) (api.post='/api/knowledge/delete', api.category="knowledge",agw.preserve_base="true")
knowledge.UpdateDatasetResponse UpdateDataset(1:knowledge.UpdateDatasetRequest req) (api.post='/api/knowledge/update', api.category="knowledge",agw.preserve_base="true")
knowledge.GetModeConfigResponse GetModeConfig(1:knowledge.GetModeConfigRequest req)(api.get='/api/memory/table_mode_config', api.category="memory", agw.preserve_base="true")
// Document related
document.CreateDocumentResponse CreateDocument(1:document.CreateDocumentRequest req) (api.post='/api/knowledge/document/create', api.category="knowledge",agw.preserve_base="true")
document.ListDocumentResponse ListDocument(1:document.ListDocumentRequest req) (api.post='/api/knowledge/document/list', api.category="knowledge",agw.preserve_base="true")
@@ -27,7 +28,7 @@ service DatasetService {
document.ExtractPhotoCaptionResponse ExtractPhotoCaption(1:document.ExtractPhotoCaptionRequest req) (api.post='/api/knowledge/photo/extract_caption', api.category="knowledge",agw.preserve_base="true")
document.GetTableSchemaResponse GetTableSchema(1:document.GetTableSchemaRequest req) (api.post='/api/knowledge/table_schema/get', api.category="knowledge",agw.preserve_base="true")
document.ValidateTableSchemaResponse ValidateTableSchema(1:document.ValidateTableSchemaRequest req) (api.post='/api/knowledge/table_schema/validate', api.category="knowledge",agw.preserve_base="true")
document.GetDocumentTableInfoResponse GetDocumentTableInfo(1:document.GetDocumentTableInfoRequest req) (api.get='/api/memory/doc_table_info', api.category="memory", agw.preserve_base="true")
// Slice related
slice.DeleteSliceResponse DeleteSlice(1:slice.DeleteSliceRequest req) (api.post='/api/knowledge/slice/delete', api.category="knowledge",agw.preserve_base="true")
slice.CreateSliceResponse CreateSlice(1:slice.CreateSliceRequest req) (api.post='/api/knowledge/slice/create', api.category="knowledge",agw.preserve_base="true")

View File

@@ -1,7 +1,7 @@
include "../../base.thrift"
include "common.thrift"
namespace go flow.dataengine.dataset
namespace go data.knowledge
struct ReviewInput {
1: string document_name

View File

@@ -1,7 +1,7 @@
include "../../base.thrift"
include "common.thrift"
namespace go flow.dataengine.dataset
namespace go data.knowledge
struct DeleteSliceRequest {
4: optional list<string> slice_ids (api.body="slice_ids") // List of sharding IDs to delete

View File

@@ -1,7 +1,9 @@
include "../../../base.thrift"
include "../table/table.thrift"
include "../../base.thrift"
include "../database/table.thrift"
include "./project_memory.thrift"
namespace go data.variable.kvmemory
struct KVItem {
1: string keyword
2: string value

View File

@@ -1,4 +1,6 @@
include "../../../base.thrift"
include "../../base.thrift"
namespace go data.variable.project_memory
enum VariableType{
KVVariable = 1

View File

@@ -1,9 +1,7 @@
include "kvmemory/kvmemory.thrift"
include "kvmemory/project_memory.thrift"
include "knowledge/kdocument.thrift"
include "table/table.thrift"
include "kvmemory.thrift"
include "project_memory.thrift"
namespace go ocean.cloud.memory
namespace go data.variable
service MemoryService {
// --- variable
@@ -15,10 +13,4 @@ service MemoryService {
kvmemory.GetSysVariableConfResponse GetSysVariableConf(1:kvmemory.GetSysVariableConfRequest req)(api.get='/api/memory/sys_variable_conf', api.category="memory")
kvmemory.SetKvMemoryResp SetKvMemory(1: kvmemory.SetKvMemoryReq req)(api.post='/api/memory/variable/upsert', api.category="memory",agw.preserve_base="true")
// ---
table.GetModeConfigResponse GetModeConfig(1:table.GetModeConfigRequest req)(api.get='/api/memory/table_mode_config', api.category="memory", agw.preserve_base="true")
kdocument.GetDocumentTableInfoResponse GetDocumentTableInfo(1:kdocument.GetDocumentTableInfoRequest req) (api.get='/api/memory/doc_table_info', api.category="memory", agw.preserve_base="true")
}

View File

@@ -1,26 +0,0 @@
struct DocTableSheet {
1: i64 id; // Number of sheet
2: string sheet_name; // Sheet name
3: i64 total_row; // total number of rows
}
enum ColumnType {
Unknown = 0
Text = 1 // Text
Number = 2 // number
Date = 3 // time
Float = 4 // float
Boolean = 5 // bool
Image = 6 // picture
}
// Table column information
struct DocTableColumn {
1: i64 id(agw.js_conv="str", api.js_conv="true", api.body="id"); // Column ID
2: string column_name; // column_name
3: bool is_semantic; // Is it a semantically matched column?
4: i64 sequence(agw.js_conv="str", api.js_conv="true", api.body="sequence"); // List the serial number originally in excel
5: optional ColumnType column_type; // column type
6: optional bool contains_empty_value
7: optional string desc; // describe
}

View File

@@ -1,33 +0,0 @@
include "../../../base.thrift"
include "common.thrift"
namespace go knowledge.document
// Get table structure, preview data
struct GetDocumentTableInfoRequest {
2: optional string tos_uri; // If the table is uploaded for the first local file, pass the value
3: optional i64 document_id(agw.js_conv="str", api.js_conv="true", api.body="document_id"); // If it is a document with an existing table, pass the value
4: i64 creator_id; // Creator [http interface does not need to be passed]
255: optional base.Base Base
}
struct GetDocumentTableInfoResponse {
1: i32 code
2: string msg
3: list<common.DocTableSheet> sheet_list
4: map<string, list<common.DocTableColumn>> table_meta(api.body="table_meta") // key: sheet_id -> list<common.DocTableColumn>
5: map<string, list<map<string,string>>> preview_data(api.body="preview_data") // key: sheet_id -> list_preview_data
255: required base.BaseResp BaseResp(api.none="true")
}
struct GetTableSchemaInfoResponse {
1: i32 code
2: string msg
3: list<common.DocTableSheet> sheet_list
4: list<common.DocTableColumn> table_meta // The schema of the selected sheet, not selected to return the first sheet by default
5: list<map<i64,string>> preview_data(agw.js_conv="str", agw.key="preview_data") // The knowledge table will return
255: optional base.BaseResp BaseResp(api.none="true")
}

View File

@@ -1,70 +0,0 @@
namespace go flow.devops.debugger.domain.infra
// ComponentType Supports component types
enum ComponentType {
Undefined = 0
CozePlugin = 10000 // Coze Plugin
CozeTool = 10001 // Coze Tool
CozeWorkflow = 10002 // Coze Workflow
CozeSubWorkflow = 10003 // Coze SubWorkflow, which is referenced in Workflow.
CozeLLMNode = 10004 // LLM nodes in Coze workflow
CozeCodeNode = 10005 // Coding nodes in a Coze workflow
CozeKnowledgeNode = 10006 // Knowledge nodes in Coze workflow
CozeToolNode = 10007 // Tools nodes in Coze workflow
CozeStartNode = 10008 // Coze workflow start node
CozeVariableNode = 10009 // Cozing variable nodes in workflow
CozeVariableBot = 20000 // Coze virtual nodes to identify variable dependent bots
CozeVariableChat = 20001 // Coze virtual nodes to identify variable dependent chats
}
// TrafficScene traffic request scenario
enum TrafficScene {
Undefined = 0
CozeSingleAgentDebug = 10000 // Single Agent Debug Page
CozeMultiAgentDebug = 10001 // Multi-Agent Debug Page
CozeToolDebug = 10002 // Tool Debug Page
CozeWorkflowDebug = 10003 // Workflow debugging page
}
// ComponentMappingType Component Mapping Types
enum ComponentMappingType {
Undefined = 0
MockSet = 1
}
// BizCtx Business Context
struct BizCtx {
1: optional string connectorID // connectorID
2: optional string connectorUID // User ID under connector
3: optional TrafficScene trafficScene // business scenario
4: optional string trafficCallerID // Business Scenario Component ID, such as Bot Debug Page, where trafficSceneID is BotID
5: optional string bizSpaceID // Line of business SpaceID for access control
6: optional map<string,string> ext // Additional information
}
// Secondary structure of the ComponentSubject business component
struct ComponentSubject {
1: optional string componentID // Component IDs, such as Tool ID, Node ID, etc
2: optional ComponentType componentType // component type
3: optional string parentComponentID // Parent component ID, e.g. Tool- > Plugin, Node- > Workflow
4: optional ComponentType parentComponentType // Parent component type
}
enum OrderBy {
UpdateTime = 1
}
struct Creator {
1: optional string ID
2: optional string name
3: optional string avatarUrl
}
enum DebugScene {
Debug = 0 // Default play ground Debug scene
}
enum CozeChannel {
Coze = 0 // Default to Coze, expand to other channels in the future
}

View File

@@ -1,21 +0,0 @@
namespace go flow.devops.debugger.domain.testcase
include "infra.thrift"
struct CaseDataBase {
1: optional i64 caseID (go.tag="json:\"caseID,string\"")// Do not fill in when adding, fill in when updating
2: optional string name
3: optional string description
4: optional string input // Input information in JSON format
5: optional bool isDefault
}
struct CaseDataDetail{
1: optional CaseDataBase caseBase
2: optional string creatorID
3: optional i64 createTimeInSec
4: optional i64 updateTimeInSec
5: optional bool schemaIncompatible // Schema incompatibility
6: optional infra.Creator updater,
}

View File

@@ -1,70 +0,0 @@
namespace go flow.devops.debugger.coze
include "../../../base.thrift"
include "./domain/infra.thrift"
include "./domain/testcase.thrift"
// ========== TestCase =========== //
struct SaveCaseDataReq {
1: optional infra.BizCtx bizCtx // business information
2: optional infra.ComponentSubject bizComponentSubject
3: optional testcase.CaseDataBase caseBase // Case basic data
255: optional base.Base Base
}
struct SaveCaseDataResp {
1: optional testcase.CaseDataDetail caseDetail
253: optional i32 code
254: optional string msg
255: optional base.BaseResp BaseResp
}
struct DeleteCaseDataReq {
1: optional infra.BizCtx bizCtx // business information
2: optional list<i64> caseIDs // A single maximum of 20
255: optional base.Base Base
}
struct DeleteCaseDataResp {
1: optional list<i64> deletedCaseIDS
253: optional i32 code
254: optional string msg
255: optional base.BaseResp BaseResp
}
struct CheckCaseDuplicateReq {
1: optional infra.BizCtx bizCtx
2: optional string caseName // Case name
3: optional infra.ComponentSubject bizComponentSubject
255: optional base.Base Base
}
struct CheckCaseDuplicateResp {
1: optional bool isPass
2: optional string failReason // When pass = false, give the specific reason why the check failed
3: optional i32 failCode
253: optional i32 code
254: optional string msg
255: optional base.BaseResp BaseResp
}
struct GetSchemaByIDReq {
1: optional infra.BizCtx bizCtx // business information
2: optional infra.ComponentSubject bizComponentSubject
255: optional base.Base Base
}
struct GetSchemaByIDResp {
1: optional string schemaJson // Component input information in JSON format, consistent with Input JSON Schema, does not contain Value information
253: optional i32 code
254: optional string msg
255: optional base.BaseResp BaseResp
}

View File

@@ -1,5 +1,5 @@
include "../../base.thrift"
namespace go flow.marketplace.marketplace_common
include "../base.thrift"
namespace go marketplace.marketplace_common
struct Price {
1: i64 Amount (agw.key = "amount",agw.js_conv="str",api.js_conv="true",agw.cli_conv="str",api.body= "amount"), // amount

View File

@@ -1,6 +1,6 @@
include "../marketplace_common.thrift"
include "marketplace_common.thrift"
namespace go flow.marketplace.product_common
namespace go marketplace.product_common
enum ProductEntityType {
Bot = 1 ,

View File

@@ -1,8 +1,8 @@
include "../../../base.thrift"
include "../base.thrift"
include "product_common.thrift"
include "../marketplace_common.thrift"
include "marketplace_common.thrift"
namespace go flow.marketplace.product_public_api
namespace go marketplace.product_public_api
service PublicProductService {
GetProductListResponse PublicGetProductList(1: GetProductListRequest req)(api.get = "/api/marketplace/product/list", api.category = "PublicAPI")

View File

@@ -1,9 +1,9 @@
include "../base.thrift"
include "../bot_common/bot_common.thrift"
include "../app/bot_common.thrift"
include "shortcut_command.thrift"
include "prompt_resource.thrift"
namespace go ocean.cloud.playground
namespace go playground
struct UpdateDraftBotInfoAgwResponse {
1: required UpdateDraftBotInfoAgwData data,
@@ -447,20 +447,6 @@ struct GetFileUrlsResponse {
255: base.BaseResp BaseResp
}
struct UploadFileOpenRequest {
1: required string ContentType (api.header = "Content-Type", agw.source = "header", agw.key = "Content-Type"), // file type
2: required binary Data (api.raw_body = ""), // binary data
255: base.Base Base
}
struct UploadFileOpenResponse {
1: optional File File (api.body = "data")
253: required i64 code
254: required string msg
255: base.BaseResp BaseResp
}
struct File{
1: string URI (api.body = "uri"), // File URI
2: i64 Bytes (api.body = "bytes"), // file bytes
@@ -469,18 +455,6 @@ struct File{
5: string URL (api.body = "url")
}
struct GetBotOnlineInfoReq {
1 : required i64 bot_id (api.js_conv="true") // botId
2: optional string connector_id // Keep it first, don't expose it, and don't use the field
3 : optional string version // bot version, get the latest version if you don't pass it on.
}
// resp
struct GetBotOnlineInfoResp {
1: required i32 code
2: required string msg
3: required bot_common.OpenAPIBotInfo data
}
service PlaygroundService {
UpdateDraftBotInfoAgwResponse UpdateDraftBotInfoAgw(1:UpdateDraftBotInfoAgwRequest request)(api.post='/api/playground_api/draftbot/update_draft_bot_info', api.category="draftbot",agw.preserve_base="true")
@@ -506,9 +480,4 @@ service PlaygroundService {
GetSpaceListV2Response GetSpaceListV2(1:GetSpaceListV2Request request)(api.post='/api/playground_api/space/list', api.category="space",agw.preserve_base="true")
MGetUserBasicInfoResponse MGetUserBasicInfo(1: MGetUserBasicInfoRequest request) (api.post='/api/playground_api/mget_user_info', api.category="playground_api",agw.preserve_base="true")
//openapi
GetBotOnlineInfoResp GetBotOnlineInfo(1: GetBotOnlineInfoReq request)(api.get='/v1/bot/get_online_info', api.category="bot", api.tag="openapi", api.gen_path="personal_api")
// File related OpenAPI
UploadFileOpenResponse UploadFileOpen(1: UploadFileOpenRequest request)(api.post = "/v1/files/upload", api.category="file", api.tag="openapi", agw.preserve_base="true")
}

View File

@@ -1,4 +1,4 @@
namespace go ocean.cloud.playground
namespace go playground
include "../base.thrift"
struct GetOfficialPromptResourceListRequest {

View File

@@ -1,4 +1,4 @@
namespace go ocean.cloud.playground
namespace go playground
include "../base.thrift"
struct CreateShortcutCommandRequest {

View File

@@ -1,7 +1,7 @@
include "../base.thrift"
include "./plugin_develop_common.thrift"
namespace go ocean.cloud.plugin_develop
namespace go plugin_develop
service PluginDevelopService {
GetOAuthSchemaResponse GetOAuthSchema(1: GetOAuthSchemaRequest request)(api.post='/api/plugin/get_oauth_schema', api.category="plugin", api.gen_path="plugin")

View File

@@ -1,4 +1,4 @@
namespace go plugin_develop.common
enum OnlineStatus {
OFFLINE = 0,
ONLINE = 1,

View File

@@ -1,5 +1,5 @@
include "../base.thrift"
include "../bot_common/bot_common.thrift"
include "../app/bot_common.thrift"
namespace go file.upload
struct CommonUploadRequest {
1: optional binary ByteData (api.raw_body = "")

View File

@@ -1,6 +1,6 @@
include "../../base.thrift"
include "../base.thrift"
namespace go ocean.cloud.workflow
namespace go workflow
enum FrontedTagType {
TEXT = 0 // Text

View File

@@ -1,6 +1,6 @@
include "../../base.thrift"
include "../base.thrift"
namespace go ocean.cloud.workflow
namespace go workflow
enum PersistenceModel {
DB = 1,

View File

@@ -1,10 +1,10 @@
include "../../base.thrift"
include "../base.thrift"
include "workflow.thrift"
include "../../resource/resource.thrift"
include "../resource/resource.thrift"
include "trace.thrift"
include "../../resource/resource_common.thrift"
include "../resource/resource_common.thrift"
namespace go ocean.cloud.workflow
namespace go workflow
service WorkflowService {
// Create process