Shake WeChat to obtain device and user information
Get device and user information
##Interface description
Get device information, including UUID, major, minor, distance, openID and other information.
Interface calling instructions
http request method: POST (please use https protocol) https:/ /api.weixin.qq.com/shakearound/user/getshakeinfo?access_token=ACCESS_TOKENPOST Data format: jsonPOST data example:
{
"ticket":"6ab3d8465166598a5f4e8c1b44f44645",
"need_poi" :1
}
Parameter Description
Parameter | Is it required | Description |
access_token | is the | calling interface credential |
ticket | is | Tickets for Shake’s surrounding businesses can be obtained from the URL you shake. The ticket is effective for 30 minutes. A new ticket will be regenerated every time you shake. |
need_poi | No | Whether it is necessary to return the store poi_id, pass 1 to return, otherwise not return; store Relevant information can be foundView the store-related interface documents |
Return instructions
Example of normal returned JSON data packet:
{
"data": {
"page_id ": 14211,
"beacon_info": {
"distance": 55.00620700469034,
"major": 10001,
"minor" : 19007,
"uuid": "FDA50693-A4E2-4FB1-AFCF-C6EB07647825"
},
"openid": "oVDmXjp7y8aG2AlBuRpMZTb1-cmA",
" poi_id":1234
},
"errcode": 0,
"errmsg": "success."
}
Parameter Description
Parameters | Description |
##beacon_info | Device information, including UUID, major, minor, and distance |
UUID, major, minor | UUID, major, minor |
distance | The distance between the Beacon signal and the mobile phone, The unit is meters |
page_id | Shake the unique ID of the surrounding page |
# #openid | The unique identifier of the user under the merchant AppID |
poi_id | Store ID, if there is one, it will be returned, otherwise it will not be in JSON format |