package org.xyzh.common.wechat.pojo.kefu;

import java.util.List;

import lombok.Data;
import lombok.EqualsAndHashCode;

/**
 * @description    同步消息响应
 * @filename    KefuSyncMsgResponse.java
 * @author    yslg
 * @copyright xyzh
 * @since 2025-12-19
 */
@Data
@EqualsAndHashCode(callSuper = true)
public class KefuSyncMsgResponse extends WeChatResponse {
    
    private String nextCursor;
    
    private Integer hasMore;
    
    private List<KefuSyncMsg> msgList;
    
    @Data
    public static class KefuSyncMsg {
        
        private String msgid;
        
        private String openKfid;
        
        private String externalUserid;
        
        private Long sendTime;
        
        private Integer origin;
        
        private String servicerUserid;
        
        private String msgtype;
        
        private TextContent text;
        
        private ImageContent image;
        
        private VoiceContent voice;
        
        private VideoContent video;
        
        private FileContent file;
        
        private LocationContent location;
        
        private LinkContent link;
        
        private BusinessCardContent businessCard;
        
        private MiniprogramContent miniprogram;
        
        private EventContent event;
        
    }
    
    @Data
    public static class TextContent {
        private String content;
        private String menuId;
    }
    
    @Data
    public static class ImageContent {
        private String mediaId;
    }
    
    @Data
    public static class VoiceContent {
        private String mediaId;
    }
    
    @Data
    public static class VideoContent {
        private String mediaId;
    }
    
    @Data
    public static class FileContent {
        private String mediaId;
    }
    
    @Data
    public static class LocationContent {
        private String latitude;
        private String longitude;
        private String name;
        private String address;
    }
    
    @Data
    public static class LinkContent {
        private String title;
        private String desc;
        private String url;
        private String picUrl;
    }
    
    @Data
    public static class BusinessCardContent {
        private String userid;
    }
    
    @Data
    public static class MiniprogramContent {
        private String title;
        private String appid;
        private String pagepath;
        private String thumbMediaId;
    }
    
    @Data
    public static class EventContent {
        private String eventType;
        private String openKfid;
        private String externalUserid;
        private String scene;
        private String sceneParam;
        private String welcomeCode;
        private String wechatChannels;
        private String failMsgid;
        private String failType;
        private String servicerUserid;
        private Integer status;
        private String changeType;
        private String oldServicerUserid;
        private String newServicerUserid;
        private String msgCode;
        private String recallMsgid;
    }
    
}
