|
@@ -16,8 +16,8 @@ public class CorpWeixinServiceImpl implements ICorpWeixinService {
|
|
public static void main(String[] args) {
|
|
public static void main(String[] args) {
|
|
val configStorage = new WxCpDefaultConfigImpl();
|
|
val configStorage = new WxCpDefaultConfigImpl();
|
|
configStorage.setCorpId("ww24b8a47826f5875f");
|
|
configStorage.setCorpId("ww24b8a47826f5875f");
|
|
- configStorage.setAgentId(1000002);
|
|
|
|
- configStorage.setCorpSecret("MJIlySADGPlgvADnkFQPUpfZD4yV-4WN6066OgNnb0s");
|
|
|
|
|
|
+ configStorage.setAgentId(1000017);
|
|
|
|
+ configStorage.setCorpSecret("jkFkOtUZPc6WVnh6lth_fUIMXSDzFcaK8tdTQ9MGbtc");
|
|
configStorage.setToken("hcst2019");
|
|
configStorage.setToken("hcst2019");
|
|
configStorage.setAesKey("hcst2019");
|
|
configStorage.setAesKey("hcst2019");
|
|
val service = new WxCpServiceImpl();
|
|
val service = new WxCpServiceImpl();
|
|
@@ -26,8 +26,8 @@ public class CorpWeixinServiceImpl implements ICorpWeixinService {
|
|
WxCpOAuth2Service wxCpOAuth2Service = new WxCpOAuth2ServiceImpl(service);
|
|
WxCpOAuth2Service wxCpOAuth2Service = new WxCpOAuth2ServiceImpl(service);
|
|
try {
|
|
try {
|
|
WxCpMessage message = new WxCpMessage();
|
|
WxCpMessage message = new WxCpMessage();
|
|
- message.setToUser("YiErSanSi");
|
|
|
|
- message.setAgentId(1000002);
|
|
|
|
|
|
+ message.setToUser("YuMeng");
|
|
|
|
+ message.setAgentId(1000017);
|
|
message.setContent("测试消息");
|
|
message.setContent("测试消息");
|
|
message.setMsgType("text");
|
|
message.setMsgType("text");
|
|
service.messageSend(message);
|
|
service.messageSend(message);
|