Commit cea888b225021e5be845ee8af21cb6d672dc8f5c

Authored by cherishsince
1 parent 95d26c9b

【优化】MidjourneyNotifyReqVO action 和 status 接受 改为 string

yudao-module-ai/yudao-module-ai-biz/src/main/java/cn/iocoder/yudao/module/ai/client/vo/MidjourneyNotifyReqVO.java
1 1 package cn.iocoder.yudao.module.ai.client.vo;
2 2  
3   -import cn.iocoder.yudao.module.ai.client.enums.MidjourneyTaskActionEnum;
4   -import cn.iocoder.yudao.module.ai.client.enums.MidjourneyTaskStatusEnum;
5 3 import io.swagger.v3.oas.annotations.media.Schema;
6 4 import lombok.Data;
7 5  
  6 +import java.util.List;
  7 +
8 8 /**
  9 + * Midjourney Proxy 通知回调
  10 + *
  11 + * - Midjourney Proxy:通知回调 bean 是 com.github.novicezk.midjourney.support.Task
  12 + * - 毫秒 api 通知回调文档地址:https://gpt-best.apifox.cn/doc-3530863
  13 + *
9 14 * @author fansili
10 15 * @time 2024/5/31 10:37
11 16 * @since 1.0
... ... @@ -16,10 +21,10 @@ public class MidjourneyNotifyReqVO {
16 21 @Schema(description = "job id")
17 22 private String id;
18 23  
19   - @Schema(description = "任务类型")
20   - private MidjourneyTaskActionEnum action;
21   - @Schema(description = "任务状态")
22   - private MidjourneyTaskStatusEnum status;
  24 + @Schema(description = "任务类型 MidjourneyTaskActionEnum")
  25 + private String action;
  26 + @Schema(description = "任务状态 MidjourneyTaskStatusEnum")
  27 + private String status;
23 28  
24 29 @Schema(description = "提示词")
25 30 private String prompt;
... ... @@ -46,4 +51,25 @@ public class MidjourneyNotifyReqVO {
46 51 @Schema(description = "失败原因")
47 52 private String failReason;
48 53  
  54 + @Schema(description = "任务完成后的可执行按钮")
  55 + private List<Button> buttons;
  56 +
  57 + @Data
  58 + public static class Button {
  59 +
  60 + @Schema(description = "MJ::JOB::upsample::1::85a4b4c1-8835-46c5-a15c-aea34fad1862 动作标识")
  61 + private String customId;
  62 +
  63 + @Schema(description = "图标 emoji")
  64 + private String emoji;
  65 +
  66 + @Schema(description = "Make Variations 文本")
  67 + private String label;
  68 +
  69 + @Schema(description = "类型,系统内部使用")
  70 + private String type;
  71 +
  72 + @Schema(description = "样式: 2(Primary)、3(Green)")
  73 + private String style;
  74 + }
49 75 }
... ...