wxpusher / wxpusher-sdk-java Goto Github PK
View Code? Open in Web Editor NEW微信消息实时推送服务[WxPusher]的Java版本sdk,可以通过API实时给个人微信推送消息。wechat pusher.
Home Page: http://wxpusher.zjiecode.com/demo
License: Apache License 2.0
微信消息实时推送服务[WxPusher]的Java版本sdk,可以通过API实时给个人微信推送消息。wechat pusher.
Home Page: http://wxpusher.zjiecode.com/demo
License: Apache License 2.0
有没有php版本
发送了信息,没有提醒,只能自己在历史发送里找到。
代码:
url = 'http://wxpusher.zjiecode.com/api/send/message/'
headers = {
'User-Agent': "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/87.0.4280.88 Safari/537.36",
'Content-Type': 'application/json'
}
payload = {
"appToken": "AT_kDV9PtZL17KqeFXaqbouFxB7pyOs165j",
"content": "Wxpusher祝你中秋节快乐!",
"summary": "消息摘要", # 消息摘要,显示在微信聊天页面或者模版消息卡片上,限制长度100,可以不传,不传默认截取content前面的内容。
# 内容类型 1表示文字 2表示html(只发送body标签内部的数据即可,不包括body标签) 3表示markdown
"contentType": 1,
"topicIds": [ # 发送目标的topicId,是一个数组!!!,也就是群发,使用uids单发的时候, 可以不传。
],
"uids": [ # 发送目标的UID,是一个数组。注意uids和topicIds可以同时填写,也可以只填写一个。
"UID_IcNAIjROboUwZL9OMcdZRCmYYJv8"
],
# 'uid': 'UID_IcNAIjROboUwZL9OMcdZRCmYYJv8',
"url": "http://wxpusher.zjiecode.com" # 原文链接,可选参数
}
resp = requests.post(url, headers=headers, params=payload)
print(resp.text)
结果:
{"code":1005,"msg":"接口 [/api/send/message/] 出现异常:Required request body is missing: public com.zjiecode.wxpusher.common.base.result.Result com.zjiecode.wxpusher.server.biz.controller.app.SendController.postSendMessage(com.zjiecode.wxpusher.server.biz.bean.SendMessageReq)","data":null,"success":false}
贵服务是免费给个人开发者提供消息推送通道,如何赚钱呢,关注人数养号?以后转成营销号?如果免费的话当我这些问题没问
在 class WxPusher中103行开始code异常,请处理
具体code如下:
if (appToken == null || appToken.isEmpty()) { return new Result(ResultCode.BIZ_FAIL, "appToken不能为空"); } if (page == null || page <= 0) { return new Result(ResultCode.BIZ_FAIL, "page不合法"); } if (page == null || page <= 0) { return new Result(ResultCode.BIZ_FAIL, "pageSize不合法"); }
另外 这是一份nodeJS-SDK
"code":1005,"msg":"接口 [/api/send/message] 出现异常:Unrecognized token 'appToken': was expecting ('true', 'false' or 'null')\n at [Source: (PushbackInputStream); line: 1, column: 10]","data":null,"success":false}
post请求https://wxpusher.zjiecode.com/api/send/message
{
"summary": "123",
"uids": [
"xxxxxx"
],
"verifyPay": false,
"appToken": "xxxxxx",
"contentType": 2,
"content": "123123 \n 213123"
}
\n不能被正确解析
发送的超级连接不能点,能够使用修改颜色。
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.