| | |
| | | import org.springframework.context.annotation.Configuration; |
| | | |
| | | @Configuration |
| | | @EnableConfigurationProperties(SmsProperties.class) |
| | | @EnableConfigurationProperties({SmsProperties.class, MailProperties.class}) |
| | | @ConditionalOnProperty(value = SmsProperties.ENABLE_KEY,matchIfMissing = true) |
| | | public class SmsConfig { |
| | | |
| | |
| | | // 实例化要请求产品(sms)的client对象,第二个参数是地域信息,可以直接填写字符串ap-guangzhou,支持的地域列表参考 https://cloud.tencent.com/document/api/382/52071#.E5.9C.B0.E5.9F.9F.E5.88.97.E8.A1.A8 |
| | | return new SmsClient(cred, "ap-guangzhou", clientProfile); |
| | | } |
| | | |
| | | |
| | | } |