chore: replace all cn comments to en version by volc api (#313)
This commit is contained in:
@@ -14,19 +14,19 @@ struct UpdateDraftBotInfoAgwResponse {
|
||||
}
|
||||
|
||||
struct UpdateDraftBotInfoAgwData {
|
||||
1: optional bool has_change // 是否有变更
|
||||
2: bool check_not_pass // true:机审校验不通过
|
||||
3: optional Branch branch // 当前是在哪个分支
|
||||
1: optional bool has_change // Is there any change?
|
||||
2: bool check_not_pass // True: The machine audit verification failed
|
||||
3: optional Branch branch // Which branch is it currently on?
|
||||
4: optional bool same_with_online
|
||||
5: optional string check_not_pass_msg // 机审校验不通过文案
|
||||
5: optional string check_not_pass_msg // The machine audit verification failed the copy.
|
||||
}
|
||||
|
||||
// 分支
|
||||
// branch
|
||||
enum Branch {
|
||||
Undefined = 0
|
||||
PersonalDraft = 1 // 草稿
|
||||
Base = 2 // space草稿
|
||||
Publish = 3 // 线上版本,diff场景下使用
|
||||
PersonalDraft = 1 // draft
|
||||
Base = 2 // Space draft
|
||||
Publish = 3 // Online version, used in diff scenarios
|
||||
}
|
||||
|
||||
struct UpdateDraftBotInfoAgwRequest {
|
||||
@@ -37,9 +37,9 @@ struct UpdateDraftBotInfoAgwRequest {
|
||||
}
|
||||
|
||||
struct GetDraftBotInfoAgwRequest {
|
||||
1: required i64 bot_id (api.js_conv='true',agw.js_conv="str") // 草稿bot_id
|
||||
2: optional string version // 查历史记录,历史版本的id,对应 bot_draft_history的id
|
||||
3: optional string commit_version // 查询指定commit_version版本,预发布使用,貌似和version是同一个东西,但是获取逻辑有区别
|
||||
1: required i64 bot_id (api.js_conv='true',agw.js_conv="str") // Draft bot_id
|
||||
2: optional string version // Check the history, the id of the historical version, corresponding to the id of the bot_draft_history
|
||||
3: optional string commit_version // Query specifies commit_version version, pre-release use, seems to be the same thing as version, but the acquisition logic is different
|
||||
|
||||
255: base.Base Base (api.none="true")
|
||||
}
|
||||
@@ -53,43 +53,43 @@ struct GetDraftBotInfoAgwResponse {
|
||||
}
|
||||
|
||||
struct GetDraftBotInfoAgwData {
|
||||
1: required bot_common.BotInfo bot_info // 核心bot数据
|
||||
2: optional BotOptionData bot_option_data // bot选项信息
|
||||
3: optional bool has_unpublished_change // 是否有未发布的变更
|
||||
4: optional BotMarketStatus bot_market_status // bot上架后的商品状态
|
||||
5: optional bool in_collaboration // bot是否处于多人协作模式
|
||||
6: optional bool same_with_online // commit内容是否和线上内容一致
|
||||
7: optional bool editable // for前端,权限相关,当前用户是否可编辑此bot
|
||||
8: optional bool deletable // for前端,权限相关,当前用户是否可删除此bot
|
||||
9: optional UserInfo publisher // 是最新发布版本时传发布人
|
||||
10: bool has_publish // 是否已发布
|
||||
11: i64 space_id (api.js_conv='true',agw.js_conv="str") // 空间id
|
||||
12: list<BotConnectorInfo> connectors // 发布的业务线详情
|
||||
13: optional Branch branch // 获取的是什么分支的内容
|
||||
14: optional string commit_version // 如果branch=PersonalDraft,则为checkout/rebase的版本号;如果branch=base,则为提交的版本
|
||||
15: optional string committer_name // for前端,最近一次的提交人
|
||||
16: optional string commit_time // for前端,提交时间
|
||||
17: optional string publish_time // for前端,发布时间
|
||||
18: optional BotCollaboratorStatus collaborator_status // 多人协作相关操作权限
|
||||
19: optional AuditInfo latest_audit_info // 最近一次审核详情
|
||||
20: optional string app_id // 抖音分身的bot会有appId
|
||||
1: required bot_common.BotInfo bot_info // core bot data
|
||||
2: optional BotOptionData bot_option_data // bot option information
|
||||
3: optional bool has_unpublished_change // Are there any unpublished changes?
|
||||
4: optional BotMarketStatus bot_market_status // The product status after the bot is put on the shelves
|
||||
5: optional bool in_collaboration // Is the bot in multiplayer cooperative mode?
|
||||
6: optional bool same_with_online // Is the content committed consistent with the online content?
|
||||
7: optional bool editable // For frontend, permission related, can the current user edit this bot
|
||||
8: optional bool deletable // For frontend, permission related, can the current user delete this bot
|
||||
9: optional UserInfo publisher // Is the publisher of the latest release version
|
||||
10: bool has_publish // Has it been published?
|
||||
11: i64 space_id (api.js_conv='true',agw.js_conv="str") // Space ID
|
||||
12: list<BotConnectorInfo> connectors // Published business line details
|
||||
13: optional Branch branch // What branch did you get the content of?
|
||||
14: optional string commit_version // If branch=PersonalDraft, the version number of checkout/rebase; if branch = base, the committed version
|
||||
15: optional string committer_name // For the front end, the most recent author
|
||||
16: optional string commit_time // For frontend, commit time
|
||||
17: optional string publish_time // For frontend, release time
|
||||
18: optional BotCollaboratorStatus collaborator_status // Multi-person collaboration related operation permissions
|
||||
19: optional AuditInfo latest_audit_info // Details of the most recent review
|
||||
20: optional string app_id // Douyin's doppelganger bot will have appId.
|
||||
}
|
||||
|
||||
struct BotOptionData {
|
||||
1: optional map<i64,ModelDetail> model_detail_map // 模型详情
|
||||
2: optional map<i64,PluginDetal> plugin_detail_map // 插件详情
|
||||
3: optional map<i64,PluginAPIDetal> plugin_api_detail_map // 插件API详情
|
||||
4: optional map<i64,WorkflowDetail> workflow_detail_map // workflow详情
|
||||
5: optional map<string,KnowledgeDetail> knowledge_detail_map // knowledge详情
|
||||
6: optional list<shortcut_command.ShortcutCommand> shortcut_command_list // 快捷指令list
|
||||
1: optional map<i64,ModelDetail> model_detail_map // model details
|
||||
2: optional map<i64,PluginDetal> plugin_detail_map // plugin details
|
||||
3: optional map<i64,PluginAPIDetal> plugin_api_detail_map // Plugin API Details
|
||||
4: optional map<i64,WorkflowDetail> workflow_detail_map // Workflow Details
|
||||
5: optional map<string,KnowledgeDetail> knowledge_detail_map // Knowledge Details
|
||||
6: optional list<shortcut_command.ShortcutCommand> shortcut_command_list // Quick command list
|
||||
}
|
||||
|
||||
|
||||
struct ModelDetail {
|
||||
1: optional string name // 模型展示名(对用户)
|
||||
2: optional string model_name // 模型名(对内部)
|
||||
3: optional i64 model_id (agw.js_conv="str" api.js_conv="true") // 模型ID
|
||||
4: optional i64 model_family // 模型类别
|
||||
1: optional string name // Model display name (to the user)
|
||||
2: optional string model_name // Model name (for internal)
|
||||
3: optional i64 model_id (agw.js_conv="str" api.js_conv="true") // Model ID
|
||||
4: optional i64 model_family // Model Category
|
||||
5: optional string model_icon_url // IconURL
|
||||
}
|
||||
|
||||
@@ -117,7 +117,7 @@ struct PluginParameter {
|
||||
3: optional bool is_required
|
||||
4: optional string type
|
||||
5: optional list<PluginParameter> sub_parameters
|
||||
6: optional string sub_type // 如果Type是数组,则有subtype
|
||||
6: optional string sub_type // If Type is an array, there is a subtype
|
||||
7: optional i64 assist_type
|
||||
}
|
||||
|
||||
@@ -127,8 +127,8 @@ struct WorkflowDetail {
|
||||
3: optional string description
|
||||
4: optional string icon_url
|
||||
5: optional i64 status
|
||||
6: optional i64 type // 类型,1:官方模版
|
||||
7: optional i64 plugin_id (agw.js_conv="str" api.js_conv="true") // workfklow对应的插件id
|
||||
6: optional i64 type // Type 1: Official Template
|
||||
7: optional i64 plugin_id (agw.js_conv="str" api.js_conv="true") // Plugin ID corresponding to workfklow
|
||||
8: optional bool is_official
|
||||
9: optional PluginAPIDetal api_detail
|
||||
}
|
||||
@@ -142,21 +142,21 @@ struct KnowledgeDetail {
|
||||
|
||||
|
||||
enum DataSetType {
|
||||
Text = 0 // 文本
|
||||
Table = 1 // 表格
|
||||
Image = 2 // 图片
|
||||
Text = 0 // Text
|
||||
Table = 1 // table
|
||||
Image = 2 // image
|
||||
}
|
||||
|
||||
|
||||
enum BotMarketStatus {
|
||||
Offline = 0 // 下架
|
||||
Online = 1 // 上架
|
||||
Offline = 0 // offline
|
||||
Online = 1 // put on the shelves
|
||||
}
|
||||
|
||||
struct UserInfo {
|
||||
1: i64 user_id (api.js_conv='true',agw.js_conv="str") // 用户id
|
||||
2: string name // 用户名称
|
||||
3: string icon_url // 用户图标
|
||||
1: i64 user_id (api.js_conv='true',agw.js_conv="str") // user id
|
||||
2: string name // user name
|
||||
3: string icon_url // user icon
|
||||
}
|
||||
|
||||
struct BotConnectorInfo {
|
||||
@@ -175,9 +175,9 @@ enum ConnectorDynamicStatus {
|
||||
|
||||
|
||||
struct BotCollaboratorStatus {
|
||||
1: bool commitable // 当前用户是否可以提交
|
||||
2: bool operateable // 当前用户是否可运维
|
||||
3: bool manageable // 当前用户是否可管理协作者
|
||||
1: bool commitable // Can the current user submit?
|
||||
2: bool operateable // Is the current user operable?
|
||||
3: bool manageable // Can the current user manage collaborators?
|
||||
}
|
||||
|
||||
struct AuditInfo {
|
||||
@@ -192,38 +192,38 @@ struct AuditResult {
|
||||
}
|
||||
|
||||
enum AuditStatus {
|
||||
Auditing = 0, // 审核中
|
||||
Success = 1, // 审核通过
|
||||
Failed = 2, // 审核失败
|
||||
Auditing = 0, // Under review.
|
||||
Success = 1, // approved
|
||||
Failed = 2, // audit failed
|
||||
}
|
||||
|
||||
|
||||
// Onboarding json结构
|
||||
// Onboarding json structure
|
||||
struct OnboardingContent {
|
||||
1: optional string prologue // 开场白(C端使用场景,只有1个;后台场景,可能为多个)
|
||||
2: optional list<string> suggested_questions // 建议问题
|
||||
1: optional string prologue // Introductory remarks (C-end usage scenarios, only 1; background scenarios, possibly multiple)
|
||||
2: optional list<string> suggested_questions // suggestion question
|
||||
3: optional bot_common.SuggestedQuestionsShowMode suggested_questions_show_mode
|
||||
}
|
||||
|
||||
enum ScopeType {
|
||||
All = 0 // 企业下所有的(企业下生效)
|
||||
Self = 1 // 我加入的(企业&个人都生效,不传默认Self)
|
||||
All = 0 // All under the enterprise (effective under the enterprise)
|
||||
Self = 1 // I joined (both companies and individuals are valid, no default self is passed on)
|
||||
}
|
||||
|
||||
struct GetSpaceListV2Request {
|
||||
1: optional string search_word // 搜索词
|
||||
2: optional i64 enterprise_id (api.js_conv='true',agw.js_conv="str") // 企业id
|
||||
3: optional i64 organization_id (api.js_conv='true',agw.js_conv="str") // 组织id
|
||||
4: optional ScopeType scope_type // 范围类型
|
||||
5: optional i32 page // 分页信息
|
||||
6: optional i32 size // 分页大小 -- page 和 size不传则认为不分页
|
||||
1: optional string search_word // Search term
|
||||
2: optional i64 enterprise_id (api.js_conv='true',agw.js_conv="str") // Enterprise ID
|
||||
3: optional i64 organization_id (api.js_conv='true',agw.js_conv="str") // organization id
|
||||
4: optional ScopeType scope_type // range type
|
||||
5: optional i32 page // paging information
|
||||
6: optional i32 size // Paging size -- if page and size are not passed on, it is considered not paging
|
||||
|
||||
255: optional base.Base Base (api.none="true")
|
||||
}
|
||||
|
||||
enum SpaceType {
|
||||
Personal = 1 // 个人
|
||||
Team = 2 // 小组
|
||||
Personal = 1 // individual
|
||||
Team = 2 // group
|
||||
}
|
||||
|
||||
enum SpaceMode {
|
||||
@@ -232,22 +232,22 @@ enum SpaceMode {
|
||||
}
|
||||
|
||||
enum SpaceTag {
|
||||
Professional = 1 // 专业版
|
||||
Professional = 1 // Professional Edition
|
||||
}
|
||||
|
||||
enum SpaceRoleType {
|
||||
Default = 0 // 默认
|
||||
Default = 0 // default
|
||||
Owner = 1 // owner
|
||||
Admin = 2 // 管理员
|
||||
Member = 3 // 普通成员
|
||||
Admin = 2 // administrator
|
||||
Member = 3 // ordinary member
|
||||
}
|
||||
|
||||
// 申请管理列表
|
||||
// Application management list
|
||||
enum SpaceApplyStatus {
|
||||
All = 0 // 所有
|
||||
Joined = 1 // 已加入
|
||||
Confirming = 2 // 确认中
|
||||
Rejected = 3 // 已拒绝
|
||||
All = 0 // all
|
||||
Joined = 1 // Joined
|
||||
Confirming = 2 // Confirming
|
||||
Rejected = 3 // Rejected
|
||||
}
|
||||
|
||||
struct AppIDInfo{
|
||||
@@ -263,37 +263,37 @@ struct ConnectorInfo{
|
||||
}
|
||||
|
||||
struct BotSpaceV2 {
|
||||
1: i64 id (api.js_conv='true',agw.js_conv="str") // 空间id,新建为0
|
||||
2: list<AppIDInfo> app_ids // 发布平台
|
||||
3: string name // 空间名称
|
||||
4: string description // 空间描述
|
||||
5: string icon_url // 图标url
|
||||
6: SpaceType space_type // 空间类型
|
||||
7: list<ConnectorInfo> connectors // 发布平台
|
||||
8: bool hide_operation // 是否隐藏新建,复制删除按钮
|
||||
9: i32 role_type // 在team中的角色 1-owner 2-admin 3-member
|
||||
10: optional SpaceMode space_mode // 空间模式
|
||||
11: bool display_local_plugin // 是否显示端侧插件创建入口
|
||||
12: SpaceRoleType space_role_type // 角色类型,枚举
|
||||
13: optional SpaceTag space_tag // 空间标签
|
||||
14: optional i64 enterprise_id (api.js_conv='true',agw.js_conv="str") // 企业id
|
||||
15: optional i64 organization_id (api.js_conv='true',agw.js_conv="str") // 组织id
|
||||
16: optional i64 owner_user_id (api.js_conv='true',agw.js_conv="str") // 空间owner uid
|
||||
17: optional string owner_name // 空间owner昵称
|
||||
18: optional string owner_user_name // 空间owner用户名
|
||||
19: optional string owner_icon_url // 空间owner图像
|
||||
20: optional SpaceApplyStatus space_apply_status // 当前访问用户加入空间状态
|
||||
21: optional i64 total_member_num // 空间成员总数,只有组织空间才查询
|
||||
1: i64 id (api.js_conv='true',agw.js_conv="str") // Space id, newly created as 0
|
||||
2: list<AppIDInfo> app_ids // publishing platform
|
||||
3: string name // space name
|
||||
4: string description // spatial description
|
||||
5: string icon_url // icon url
|
||||
6: SpaceType space_type // space type
|
||||
7: list<ConnectorInfo> connectors // publishing platform
|
||||
8: bool hide_operation // Whether to hide New, Copy Delete buttons
|
||||
9: i32 role_type // Role in team 1-owner 2-admin 3-member
|
||||
10: optional SpaceMode space_mode // Spatial Mode
|
||||
11: bool display_local_plugin // Whether to display the end-side plug-in creation entry
|
||||
12: SpaceRoleType space_role_type // Role type, enumeration
|
||||
13: optional SpaceTag space_tag // spatial label
|
||||
14: optional i64 enterprise_id (api.js_conv='true',agw.js_conv="str") // Enterprise ID
|
||||
15: optional i64 organization_id (api.js_conv='true',agw.js_conv="str") // organization id
|
||||
16: optional i64 owner_user_id (api.js_conv='true',agw.js_conv="str") // Space owner uid
|
||||
17: optional string owner_name // Space owner nickname
|
||||
18: optional string owner_user_name // Space owner username
|
||||
19: optional string owner_icon_url // Space owner image
|
||||
20: optional SpaceApplyStatus space_apply_status // The current visiting user joins the space status
|
||||
21: optional i64 total_member_num // The total number of space members, only the organization space can be queried.
|
||||
}
|
||||
|
||||
struct SpaceInfo {
|
||||
1: list<BotSpaceV2> bot_space_list // 用户加入空间列表
|
||||
2: bool has_personal_space // 是否有个人空间
|
||||
3: i32 team_space_num // 个人创建team空间数量
|
||||
4: i32 max_team_space_num // 个人最大能创建的空间数量
|
||||
5: list<BotSpaceV2> recently_used_space_list // 最近使用空间列表
|
||||
6: optional i32 total // 分页时生效
|
||||
7: optional bool has_more // 分页时生效
|
||||
1: list<BotSpaceV2> bot_space_list // User joins space list
|
||||
2: bool has_personal_space // Is there any personal space available?
|
||||
3: i32 team_space_num // Number of team spaces created by individuals
|
||||
4: i32 max_team_space_num // The maximum number of spaces an individual can create
|
||||
5: list<BotSpaceV2> recently_used_space_list // list of recently used spaces
|
||||
6: optional i32 total // Effective when paging
|
||||
7: optional bool has_more // Effective when paging
|
||||
}
|
||||
|
||||
struct GetSpaceListV2Response {
|
||||
@@ -311,7 +311,7 @@ struct GetImagexShortUrlResponse{
|
||||
}
|
||||
|
||||
struct GetImagexShortUrlData {
|
||||
1: map<string,UrlInfo> url_info //审核状态,key uri,value url 和 审核状态
|
||||
1: map<string,UrlInfo> url_info //Audit status, key uri, value url and, audit status
|
||||
|
||||
}
|
||||
|
||||
@@ -338,18 +338,18 @@ struct GetImagexShortUrlRequest{
|
||||
|
||||
struct UserBasicInfo {
|
||||
1: required i64 UserId (api.js_conv='true',agw.js_conv="str", api.body="user_id")
|
||||
3: required string Username (api.body="user_name") // 昵称
|
||||
4: required string UserAvatar (api.body="user_avatar") // 头像
|
||||
5: optional string UserUniqueName (api.body="user_unique_name") // 用户名
|
||||
6: optional bot_common.UserLabel UserLabel (api.body="user_label") // 用户标签
|
||||
7: optional i64 CreateTime (api.body="create_time") // 用户创建时间
|
||||
3: required string Username (api.body="user_name") // nickname
|
||||
4: required string UserAvatar (api.body="user_avatar") // avatar
|
||||
5: optional string UserUniqueName (api.body="user_unique_name") // user name
|
||||
6: optional bot_common.UserLabel UserLabel (api.body="user_label") // user tag
|
||||
7: optional i64 CreateTime (api.body="create_time") // user creation time
|
||||
}
|
||||
|
||||
struct MGetUserBasicInfoRequest {
|
||||
1 : required list<string> UserIds (agw.js_conv="str", api.js_conv="true", api.body="user_ids")
|
||||
2 : optional bool NeedUserStatus (api.body="need_user_status")
|
||||
3 : optional bool NeedEnterpriseIdentity (api.body="need_enterprise_identity") // 是否需要企业认证信息,前端通过AGW调用时默认为true
|
||||
4 : optional bool NeedVolcanoUserName (api.body="need_volcano_user_name") // 是否需要火山用户名
|
||||
3 : optional bool NeedEnterpriseIdentity (api.body="need_enterprise_identity") // Whether enterprise authentication information is required, the default is true when the front end is called through AGW
|
||||
4 : optional bool NeedVolcanoUserName (api.body="need_volcano_user_name") // Do you need a volcano username?
|
||||
|
||||
255: optional base.Base Base (api.none="true")
|
||||
}
|
||||
@@ -405,7 +405,7 @@ struct ReportUserBehaviorRequest {
|
||||
1: required i64 ResourceID (api.body = "resource_id",api.js_conv="true")
|
||||
2: required SpaceResourceType ResourceType (api.body="resource_type")
|
||||
3: required BehaviorType BehaviorType (api.body="behavior_type")
|
||||
4: optional i64 SpaceID (agw.js_conv="str",api.js_conv="true",api.body="space_id",agw.key="space_id") // 本需求必传
|
||||
4: optional i64 SpaceID (agw.js_conv="str",api.js_conv="true",api.body="space_id",agw.key="space_id") // This requirement must be passed on
|
||||
|
||||
255: base.Base Base (api.none="true")
|
||||
}
|
||||
@@ -448,8 +448,8 @@ struct GetFileUrlsResponse {
|
||||
}
|
||||
|
||||
struct UploadFileOpenRequest {
|
||||
1: required string ContentType (api.header = "Content-Type", agw.source = "header", agw.key = "Content-Type"), // 文件类型
|
||||
2: required binary Data (api.raw_body = ""), // 二进制数据
|
||||
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
|
||||
}
|
||||
|
||||
@@ -462,17 +462,17 @@ struct UploadFileOpenResponse {
|
||||
}
|
||||
|
||||
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"), // 文件名
|
||||
1: string URI (api.body = "uri"), // File URI
|
||||
2: i64 Bytes (api.body = "bytes"), // file bytes
|
||||
3: i64 CreatedAt (agw.key = "created_at"), // Upload timestamp in s
|
||||
4: string FileName (api.body = "file_name"), // file name
|
||||
5: string URL (api.body = "url")
|
||||
}
|
||||
|
||||
struct GetBotOnlineInfoReq {
|
||||
1 : required i64 bot_id (api.js_conv="true") // botId
|
||||
2: optional string connector_id // 先保留,不暴露且不使用该字段
|
||||
3 : optional string version // bot版本,不传则获取最新版本
|
||||
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
|
||||
@@ -492,7 +492,7 @@ service PlaygroundService {
|
||||
UpdateBotPopupInfoResponse UpdateBotPopupInfo (1:UpdateBotPopupInfoRequest request)(api.post='/api/playground_api/operate/update_bot_popup_info', api.category="account",agw.preserve_base="true")
|
||||
ReportUserBehaviorResponse ReportUserBehavior(1:ReportUserBehaviorRequest request)(api.post='/api/playground_api/report_user_behavior', api.category="playground_api",agw.preserve_base="true")
|
||||
|
||||
// 创建快捷指令
|
||||
// Create shortcut instructions
|
||||
shortcut_command.CreateUpdateShortcutCommandResponse CreateUpdateShortcutCommand(1: shortcut_command.CreateUpdateShortcutCommandRequest req)(api.post='/api/playground_api/create_update_shortcut_command', api.category="playground_api", agw.preserve_base="true")
|
||||
GetFileUrlsResponse GetFileUrls(1: GetFileUrlsRequest req)(api.post='/api/playground_api/get_file_list', api.category="playground_api", agw.preserve_base="true")
|
||||
|
||||
@@ -509,6 +509,6 @@ service PlaygroundService {
|
||||
//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 相关 OpenAPI
|
||||
// File related OpenAPI
|
||||
UploadFileOpenResponse UploadFileOpen(1: UploadFileOpenRequest request)(api.post = "/v1/files/upload", api.category="file", api.tag="openapi", agw.preserve_base="true")
|
||||
}
|
||||
|
||||
@@ -68,7 +68,7 @@ struct DeletePromptResourceResponse {
|
||||
255: required base.BaseResp BaseResp
|
||||
}
|
||||
|
||||
// 参数优先级从上往下
|
||||
// Parameter priority from top to bottom
|
||||
struct SyncPromptResourceToEsRequest {
|
||||
1: optional bool SyncAll
|
||||
2: optional list<i64> PromptResourceIDList
|
||||
@@ -84,8 +84,8 @@ struct SyncPromptResourceToEsResponse {
|
||||
|
||||
|
||||
struct MGetDisplayResourceInfoRequest {
|
||||
1 : list<i64> ResIDs, // 最大传一页的数量,实现方可以限制最大100个
|
||||
2 : i64 CurrentUserID, // 当前的用户,实现方用于判断权限
|
||||
1 : list<i64> ResIDs, // The maximum number of one page can be transferred, and the implementer can limit the maximum to 100.
|
||||
2 : i64 CurrentUserID, // The current user, the implementation is used to determine the authority
|
||||
255: base.Base Base ,
|
||||
}
|
||||
|
||||
@@ -95,36 +95,36 @@ struct MGetDisplayResourceInfoResponse {
|
||||
}
|
||||
|
||||
enum ActionKey{
|
||||
Copy = 1, //复制
|
||||
Delete = 2, //删除
|
||||
EnableSwitch = 3, //启用/禁用
|
||||
Edit = 4, //编辑
|
||||
CrossSpaceCopy = 10, // 跨空间复制
|
||||
Copy = 1, //copy
|
||||
Delete = 2, //delete
|
||||
EnableSwitch = 3, //enable/disable
|
||||
Edit = 4, //edit
|
||||
CrossSpaceCopy = 10, //Cross-space copy
|
||||
}
|
||||
|
||||
struct ResourceAction{
|
||||
// 一个操作对应一个唯一的key,key由资源侧约束
|
||||
// An operation corresponds to a unique key, and the key is constrained by the resource side
|
||||
1 : required ActionKey Key (go.tag = "json:\"key\""),
|
||||
//ture=可以操作该Action,false=置灰
|
||||
//ture = can operate this Action, false = grey out
|
||||
2 : required bool Enable (go.tag = "json:\"enable\""),
|
||||
}
|
||||
|
||||
// 展示用,实现方提供展示信息
|
||||
// For display, the implementer provides display information
|
||||
struct DisplayResourceInfo{
|
||||
1 : optional i64 ResID, // 资源id
|
||||
5 : optional string Desc,// 资源描述
|
||||
6 : optional string Icon,// 资源Icon,完整url
|
||||
12 : optional i32 BizResStatus, // 资源状态,各类型资源自身定义
|
||||
13 : optional bool CollaborationEnable, // 是否开启多人编辑
|
||||
16 : optional map<string, string> BizExtend, // 业务携带的扩展信息,以res_type区分,每个res_type定义的schema和含义不一样,使用前需要判断res_type
|
||||
17 : optional list<ResourceAction> Actions, // 不同类型的不同操作按钮,由资源实现方和前端约定。返回则展示,要隐藏某个按钮,则不要返回;
|
||||
18 : optional bool DetailDisable, // 是否禁止进详情页
|
||||
19 : optional string Name // 资源名称
|
||||
20 : optional ResourcePublishStatus PublishStatus, // 资源发布状态,1-未发布,2-已发布
|
||||
21 : optional i64 EditTime, // 最近编辑时间, unix秒级时间戳
|
||||
1 : optional i64 ResID, // Resource ID
|
||||
5 : optional string Desc,// resource description
|
||||
6 : optional string Icon,// Resource Icon, full url
|
||||
12 : optional i32 BizResStatus, // Resource status, each type of resource defines itself
|
||||
13 : optional bool CollaborationEnable, // Whether to enable multi-person editing
|
||||
16 : optional map<string, string> BizExtend, // Business carry extended information to res_type distinguish, each res_type defined schema and meaning is not the same, need to judge before use res_type
|
||||
17 : optional list<ResourceAction> Actions, // Different types of different operation buttons are agreed upon by the resource implementer and the front end. Return is displayed, if you want to hide a button, do not return;
|
||||
18 : optional bool DetailDisable, // Whether to ban entering the details page
|
||||
19 : optional string Name // resource name
|
||||
20 : optional ResourcePublishStatus PublishStatus, // Resource release status, 1 - unpublished, 2 - published
|
||||
21 : optional i64 EditTime, // Last edited, unix timestamp
|
||||
}
|
||||
|
||||
enum ResourcePublishStatus{
|
||||
UnPublished = 1, //未发布
|
||||
Published = 2, //已发布
|
||||
UnPublished = 1, //unpublished
|
||||
Published = 2, //Published
|
||||
}
|
||||
@@ -17,27 +17,27 @@ struct CreateShortcutCommandResponse {
|
||||
|
||||
|
||||
struct ShortcutStruct {
|
||||
16: optional list<string> shortcut_sort // 快捷指令ID列表 实体上绑定的
|
||||
17: optional list<ShortcutCommand> shortcut_list // 快捷指令内容list
|
||||
16: optional list<string> shortcut_sort // Shortcut ID list, bound on the entity
|
||||
17: optional list<ShortcutCommand> shortcut_list // Quick command content list
|
||||
}
|
||||
|
||||
struct ShortcutCommand {
|
||||
2 : i64 object_id (api.js_conv="true") // 绑定实体ID
|
||||
3 : string command_name // 命令名称
|
||||
4 : string shortcut_command // 快捷指令
|
||||
5 : string description // 描述
|
||||
6 : SendType send_type // 发送类型
|
||||
7 : ToolType tool_type // 使用工具type
|
||||
2 : i64 object_id (api.js_conv="true") // Binding Entity ID
|
||||
3 : string command_name // command name
|
||||
4 : string shortcut_command // Quick Instruction
|
||||
5 : string description // describe
|
||||
6 : SendType send_type // Send type
|
||||
7 : ToolType tool_type // Use tool type
|
||||
8 : string work_flow_id
|
||||
9 : string plugin_id
|
||||
10: string plugin_api_name
|
||||
11 : string template_query // 模板query
|
||||
12 : list<Components> components_list // panel参数
|
||||
15 : string card_schema // 表单的schema
|
||||
16 : i64 command_id (api.js_conv="true") // 指令ID
|
||||
17 : ToolInfo tool_info //工具信息 包含name+变量列表+...
|
||||
18 : ShortcutFileInfo shortcut_icon // 指令图标
|
||||
21 : optional string agent_id //multi的指令时,该指令由哪个节点执行
|
||||
11 : string template_query // Template query
|
||||
12 : list<Components> components_list // Panel parameters
|
||||
15 : string card_schema // Form schema
|
||||
16 : i64 command_id (api.js_conv="true") // Instruction ID
|
||||
17 : ToolInfo tool_info //Tool information, including name + variable list +...
|
||||
18 : ShortcutFileInfo shortcut_icon // command icon
|
||||
21 : optional string agent_id //Multi instruction, which node executes the instruction
|
||||
22 : i64 plugin_api_id (api.js_conv="true")
|
||||
}
|
||||
|
||||
@@ -47,15 +47,15 @@ struct ShortcutFileInfo {
|
||||
}
|
||||
|
||||
|
||||
struct Components { // panel参数
|
||||
struct Components { // Panel parameters
|
||||
1 : string name
|
||||
2 : string description
|
||||
3 : InputType input_type
|
||||
4 : string parameter // 请求工具时,参数的key
|
||||
4 : string parameter // When requesting the tool, the key of the parameter
|
||||
5 : list<string> options
|
||||
6 : DefaultValue default_value
|
||||
7 : bool hide // 是否隐藏不展示
|
||||
8 : list<InputType> upload_options // input_type为MixUpload时,支持哪些类型
|
||||
7 : bool hide // Whether to hide or not to show
|
||||
8 : list<InputType> upload_options // What types are supported input_type MixUpload
|
||||
}
|
||||
|
||||
struct DefaultValue {
|
||||
@@ -65,26 +65,26 @@ struct DefaultValue {
|
||||
|
||||
struct ToolInfo {
|
||||
1:string tool_name
|
||||
2:list<ToolParams> tool_params_list // 变量列表 插件&workFLow
|
||||
2:list<ToolParams> tool_params_list // Variable lists, plugins & workFLow
|
||||
}
|
||||
|
||||
struct ToolParams { // 参数列表
|
||||
struct ToolParams { // parameter list
|
||||
1 : string name
|
||||
2 : bool required
|
||||
3 : string desc
|
||||
4 : string type
|
||||
6 : string default_value // 默认值
|
||||
8 : bool refer_component // 是否是panel参数
|
||||
6 : string default_value // default value
|
||||
8 : bool refer_component // Is it a panel parameter?
|
||||
}
|
||||
|
||||
enum SendType {
|
||||
SendTypeQuery = 0 // 直接发query
|
||||
SendTypePanel = 1 // 使用面板
|
||||
SendTypeQuery = 0 // Send query directly
|
||||
SendTypePanel = 1 // use panel
|
||||
}
|
||||
|
||||
enum ToolType {
|
||||
ToolTypeWorkFlow = 1 // 使用WorkFlow
|
||||
ToolTypePlugin = 2 // 使用插件
|
||||
ToolTypeWorkFlow = 1 // Using WorkFlow
|
||||
ToolTypePlugin = 2 // use plug-ins
|
||||
}
|
||||
|
||||
enum InputType {
|
||||
|
||||
Reference in New Issue
Block a user