package cn.aqroid.business.auth.config;

import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.stereotype.Component;

/**
 * 微信小程序配置
 *
 * @author aqroid
 * @date 2026-01-12
 */
@Component
@ConfigurationProperties(prefix = "wx.miniapp")
public class WxConfig {

    /** 小程序AppID */
    private String appId;

    /** 小程序AppSecret */
    private String appSecret;

    /** Token有效期（秒），默认7天 */
    private Long tokenExpireTime = 604800L;

    public String getAppId() {
        return appId;
    }

    public void setAppId(String appId) {
        this.appId = appId;
    }

    public String getAppSecret() {
        return appSecret;
    }

    public void setAppSecret(String appSecret) {
        this.appSecret = appSecret;
    }

    public Long getTokenExpireTime() {
        return tokenExpireTime;
    }

    public void setTokenExpireTime(Long tokenExpireTime) {
        this.tokenExpireTime = tokenExpireTime;
    }
}
