package com.ruoyi.ss.access.domain;

import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.annotation.Sensitive;
import com.ruoyi.common.core.domain.BaseEntity;
import com.ruoyi.common.enums.DesensitizedType;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.time.LocalDateTime;

/**
 * 第三方API秘钥对对象 ss_access
 *
 * @author ruoyi
 * @date 2024-07-17
 */
@Data
public class Access extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 秘钥对ID */
    private Long accessId;

    /** 申请用户ID */
    @Excel(name = "申请用户ID")
    private Long userId;

    /** 秘钥键 */
    @Excel(name = "秘钥键")
    private String accessKey;

    /** 秘钥（加密） */
    @Excel(name = "秘钥")
    @Sensitive(desensitizedType = DesensitizedType.PASSWORD)
    private String accessSecret;

    @ApiModelProperty("到期时间")
    private LocalDateTime expireTime;

    @ApiModelProperty("剩余调用次数")
    private Integer surplusCount;
}
