# wisdom #Public, and micro-intelligence is a separate product of micro-intelligence, each with an openid to send messages
I. A micro-mail program sends a message only if:
1. Micro-credit payback

2. Upon submission of the form form
Micro-credit access to openid steps (both in official web api files):
Official web api documents address: https://developmenters. Weixin. Qq. Com/miniprogram/dev/api/
1. Call interface wx. Login() to get temporary login vouchers (code) will return
2. Request: https://api. Weixin. Qq. Com/sns/jscode2session? Appid=appid&secret=secret&js code=jscode&grant type=authorization code
parameter description: app app applet unique identifier
code glant type when js code login

Micro-credit public access step (both online api files):
Web site api document address: https://mp. Weixin. Qq. Com/wiki? T=resource/res main&id=mp1445241432
1. Access token first (appid, secret, not a small program, remember)
https request mode: get
https://api. Weixin. Qq. Com/cgi-bin/token? Grant type=clent credential&appid=appid&secret=appsecret
2. Access to user openid
micro-cyberpass provides access to user list interfaces (i. E., access to all user information that follows the micro-cyberpass)
request address: https://api. Weixin. Qq. Com/cgi-bin/user/get? Access token=access token&next openid=nex openid
openid, next openid = available at https://api. Weixin. Qq. Com/cgi-bin/user/get? Access token=access token&next openid=
3. Access to basic user information
interface call request description
http request mode: get
https://api. Weixin. Qq. Com/cgi-bin/user/info? Access token=access token&openid=openid&lang=zh cn

Okay, the little program's openid, the public sign's openid, the but, it's useless to get through the little program, the public code, and the individual openid, because the two sets of products, each defending its own openid, so, the communicator has created an unionid mechanism, which is that all the products under the flag of communicator have a single sign for the user: unionid, how to get unionid? Register a developer account, bind a public number, a small program, a specified applet, a public number under the same developer, so that when you get a public number, an openid returns to unioNid (same, happy) so that the database can store the public number, the small program, the openid, the anti-public number, and send the template message to the public..
One wave, encapsulation parameters:
Http request mode: post
https://api. Weixin. Qq. Com/cgi-bin/message/template/send? Access token=access token
post data
other organiser
"touser": "openid",
"template id": "ngqipbwh8bufcssecmogfxcv14jtqlepbo27ey"
"url": "http://weixin. Qq. Com/download",
"miniprogram":
"appid": "xiaochenggxuappid12345",
"pagepath": "index? Foo=bar"
♪ i don't know ♪
"data":
"first":
"value": "congratulations on your purchase!"
"color: #173177"
♪ i don't know ♪
"keyword1":
"value": "cool,"
"color: #173177"
♪ i don't know ♪
"keyword2":
"value": "39. 8."
"color: #173177"
♪ i don't know ♪
"keyword3": {
"value": "september 22, 2014",
"color: #173177"
♪ i don't know ♪
"remark":
"value": "welcome to buy again!"
"color: #173177"
♪ i'm sorry ♪
♪ i'm sorry ♪
♪ i'm sorry ♪
the access token here is a micro-public. Note:
pagepath cannot start with / (jump page link for applet)
appid use applet

Java object envelope (individual does not recommend map envelope, suggests object envelope)
II don't know. II don't know. II don't know.
@getter
@setter
i'm sorry, i'm sorry, but i'm sorry. I don't know. I don't know. I'm sorry. Pryvate mapI'm sorry. I'm sorry.
♪ i'm sorry ♪
@getter
@setter
this post is part of our special coverage global voices 2011. I'm sorry. Private spring;
♪ i'm sorry ♪
@setter
@getter
this post is part of our special coverage syria protests 2011. I don't know. I don't know.
♪ i'm sorry ♪ 



