| | |
| | | import com.aliyun.sdk.service.dysmsapi20170525.models.SendSmsRequest; |
| | | import com.aliyun.sdk.service.dysmsapi20170525.models.SendSmsResponse; |
| | | import com.aliyun.sdk.service.dysmsapi20170525.models.SendSmsResponseBody; |
| | | import com.zy.crm.common.entity.PhoneCodeTypeParam; |
| | | import darabonba.core.client.ClientOverrideConfiguration; |
| | | |
| | | import java.util.*; |
| | |
| | | /** |
| | | * 阿里云市场API 分配了新的规划申请单任务!请注意查收! |
| | | */ |
| | | private static boolean aliyun_2(String phone, String code) { |
| | | private static boolean aliyun_2(String phone, PhoneCodeTypeParam phoneCodeTypeParam) { |
| | | try { |
| | | HashMap<String, Object> headers = new HashMap<>(); |
| | | HashMap<String, Object> param = new HashMap<>(); |
| | |
| | | String APPCODE = "15ce5d8be5e348c7b680dfd7cfb8307e"; |
| | | headers.put("Authorization", "APPCODE " + APPCODE); |
| | | |
| | | param.put("templateId", "M6F3C81FE3"); |
| | | param.put("receive", "13083813523"); |
| | | param.put("tag", code); |
| | | param.put("templateId", phoneCodeTypeParam.templateId); |
| | | param.put("receive", phone); |
| | | param.put("tag", ""); |
| | | |
| | | String response = new HttpHandler.Builder() |
| | | .setUri("https://smkjdxtzjk.market.alicloudapi.com") |
| | |
| | | /** |
| | | * 发送短信-阿里云原生 |
| | | */ |
| | | public static boolean sendSmsCodeText(String phone, String code) { |
| | | return aliyun_2(phone, code); |
| | | public static boolean sendSmsCodeText(String phone, PhoneCodeTypeParam param) { |
| | | return aliyun_2(phone, param); |
| | | } |
| | | |
| | | /** |