1.Overview
Developers send required parameters to server to generate QRcode room card.
2.Examples
Language Explanation Download Version
php php_sdk instructions Download SDK and DEMO V2.0
java java_sdk instructions Download SDK and DEMO V2.0
c# c#_sdk instructions Download SDK and DEMO V2.0
3. Request URL
4. Request parameter format
/?c=Qrcode&a=getLink&sig={sig}
Sig is the encryption result of developer account SID and Auth Token, get details in Development documentation
HTTP request header:
Accept:application/json;
Content-Type:application/x-www-form-urlencode;charset=uft-8;
Authorization:XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
{"mobile":"1330000000","communityNo":"13444456566","buildNo":"001","floorNo":"001","roomNo":"101","startTime":"1511201800","endTime":"1511211200","areaCode":"86","sendSms":"1"}
5. Parameter specification
Attribute Type Constraint Explanation
accountSid String Required Developer Account SID, the unique identifier of developer(32 characters of letters and numbers).
sig String Required Signature, API request required.
Accept String Required Standard HTTP header, content-type: application/json
Content-Type String Required Standard HTTP header, type:application/x-www-form-urlencode;charset=utf-8
Authorization String Required HTTP header authentication information
mobile String Required Mobile
communityNo String Required Community No.
buildNo String Optional Building number (notice: building number is optional, and floor number is required too if building number exists.)
floorNo String Optional Floor number (notice: floor number is optional, and building number is required too if floor number exists.)
roomNo String Required Room number(notice: if request parameters don't include building number and floor number, make sure your room number is unique in this community.)
startTime String Optional QRcode effective start time format: 1506161230 June 16th, 2015 at 12:30, when this parameter is not passed, the effective start time of the room card is the current time of the server.
endTime String Optional QRcode effective end time format: 1506161230 June 16th, 2015 at 12:30, when this parameter is not passed, The effective end time of the room card is the current time of the server plus the Community setup time,If the Community's card time is not set, the default is the current time plus five minutes.
areaCode String Optional Mobile users belong to the country code (default 86)
sendSms String Optional Whether to send a message, 1= send, 0= do not send, default 0.(Note: test accounts not support this option)
cardType String Optional Key type (0: room card, 1: floor card, 2: building card, default 0 when not being transmitted).
6. HTTP JSON request demo
HTTP header
Accept:application/json;
Content-Type:application/x-www-form-urlencode;charset=uft-8;
Authorization:XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
{"mobile":"1330000000","communityNo":"13444456566","buildNo":"001","floorNo":"001","roomNo":"101","startTime":"1511201800","endTime":"1511211200","sendSms":"1","cardType":"0"}
Http Request parameters
/?c=Qrcode&a=getLink&sig=031A94222BB0AF73AA0DCDEB92D54609
Success responce(no: room card unique number): users can get QRcode keys in 'QRMaster QRcode key entrance' after identity authentication via mobile number.
{"status":200,"info":"success","no":"2EwNXzAmR9Voq67x","cardType":"2EwNXzAmR9Voq67x"}
Fail result:
{ "status": 403, "info": "some error" }
7. XML request demo
HTTP header
Accept:application/xml;
Content-Type:application/x-www-form-urlencode;charset=uft-8;
Authorization:XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
<?xml version='1.0' encoding='utf-8'?>
<Request>
<mobile>18819238549</mobile>
<communityNo>1316879800</communityNo>
<buildNo>1</buildNo>
<floorNo>1</floorNo>
<roomNo>401G</roomNo>
<startTime>1511201200</startTime>
<endTime>1511211200</endTime>
<areaCode>86</areaCode>
<sendSms>1</sendSms>
<cardType>0</cardType>
</Request>
Http Request parameters
/?c=Qrcode&a=getLink&sig=031A94222BB0AF73AA0DCDEB92D54609
Success responce(no: room card unique number): users can get QRcode keys in 'QRMaster QRcode key entrance' after identity authentication via mobile number.
<?xml version="1.0" encoding="UTF-8" ?>
<Response>
<status>200</status>
<info>success</info>
<no>2EwNXzAmR9Voq67x</no>
<cardType>2EwNXzAmR9Voq67x</cardType>
</Response>
Fail result:
<?xml version="1.0" encoding="UTF-8" ?>
<Response>
<status>4003</status>
<info> some error </info>
</Response>
Sales
Software
Aftersales
Telephone
400-8618286