import "../base.api" import "./work_experience.api" import "./tutorial.api" import "./employee_config.api" type ( // The data of employee information | Employee信息 EmployeeInfo { BaseIDInfo // title | 标题 Title *string `json:"title,optional"` // avatar | 头像 Avatar *string `json:"avatar,optional"` // tags | 个人标签 Tags *string `json:"tags,optional"` // hire_count | 被雇佣次数 HireCount *int `json:"hireCount,optional"` // service_count | 已服务次数 ServiceCount *int `json:"serviceCount,optional"` // achievement_count | 业绩单数 AchievementCount *int `json:"achievementCount,optional"` // category_id | 分类ID CategoryId *uint64 `json:"categoryId,optional"` // intro | 个人介绍 Intro *string `json:"intro,optional"` // estimate | 自我评价 Estimate *string `json:"estimate,optional"` // skill | 技能卡 Skill *string `json:"skill,optional"` // ability_type | 能力类型 AbilityType *string `json:"abilityType,optional"` // scene | 使用场景 Scene *string `json:"scene,optional"` SceneList []EmployeeConfigInfo `json:"sceneList,optional"` // switch_in | 支持介入 SwitchIn *string `json:"switchIn,optional"` SwitchInList []EmployeeConfigInfo `json:"switchInList,optional"` Tutorial []TutorialInfo `json:"tutorial,optional"` // video_url | 视频地址 VideoUrl *string `json:"videoUrl,optional"` // work_experience | 工作经验 WorkExperience []WorkExperienceInfo `json:"workExperience,optional"` ApiBase *string `json:"apiBase,optional"` ApiKey *string `json:"apiKey,optional"` // AI信息 AiInfo *string `json:"aiInfo,optional"` ShowChat *bool `json:"showChat,optional"` IsVip *bool `json:"isVip,optional"` ChatUrl *string `json:"chatUrl,optional"` } // The response data of employee list | Employee列表数据 EmployeeListResp { BaseDataInfo // Employee list data | Employee列表数据 Data EmployeeListInfo `json:"data"` } // Employee list data | Employee列表数据 EmployeeListInfo { BaseListInfo // The API list data | Employee列表数据 Data []EmployeeInfo `json:"data"` } // Get employee list request params | Employee列表请求参数 EmployeeListReq { PageInfo // title | 标题 Title *string `json:"title,optional"` // tags | 个人标签 Tags *string `json:"tags,optional"` // category_id | 分类ID CategoryId *uint64 `json:"categoryId,optional"` } // Employee information response | Employee信息返回体 EmployeeInfoResp { BaseDataInfo // Employee information | Employee数据 Data EmployeeInfo `json:"data"` } AuthReq { Token *string `json:"token,optional"` Data uint64 `json:"data,optional"` } AuthResp { Token *string `json:"token,optional"` Data *uint64 `json:"data,optional"` Original interface{} `json:"original,optional"` OK interface{} `json:"ok,optional"` SecretKey string `json:"secretKey,optional"` } ) @server( group: employee ) service Wechat { // Get employee list | 获取Employee列表 @handler getApiEmployeeList post /api/employee/list (EmployeeListReq) returns (EmployeeListResp) // Get employee by ID | 通过ID获取Employee @handler getApiEmployeeDetail post /api/employee/detail (IDReq) returns (EmployeeInfoResp) } @server( group: employee ) service Wechat { // Get employee list | 获取Employee列表 @handler getEmployeeSearch post /employee/search (EmployeeListReq) returns (EmployeeListResp) // Get employee list | 获取Employee列表 @handler getEmployeeSearchTest post /employee/search/test (AuthReq) returns (AuthResp) // Get employee by ID | 通过ID获取Employee @handler getEmployeeDetail post /employee/detail (IDReq) returns (EmployeeInfoResp) } @server( jwt: Auth group: employee middleware: Authority ) service Wechat { // Create employee information | 创建Employee @handler createEmployee post /employee/create (EmployeeInfo) returns (BaseMsgResp) // Update employee information | 更新Employee @handler updateEmployee post /employee/update (EmployeeInfo) returns (BaseMsgResp) // Delete employee information | 删除Employee信息 @handler deleteEmployee post /employee/delete (IDsReq) returns (BaseMsgResp) // Get employee list | 获取Employee列表 @handler getEmployeeList post /employee/list (EmployeeListReq) returns (EmployeeListResp) // Get employee by ID | 通过ID获取Employee @handler getEmployeeById post /employee (IDReq) returns (EmployeeInfoResp) }