Chimaguan side of the SDK download, run not up, Baidu search some also did not find too many articles, only a CSDN blog wrote an article, more reference value
Consult the documentation in more detail for a few days. The following considerations are sorted out:
Access to the Sesame API interface, should be divided into 2 steps:
The first step, get the authorization, this, the official SDK, as long as the parameters are configured correctly, you can operate. Note the following parameters, compared to the sesame document,
In addition, the most important point,,, sesame public key generation, as well as modified, generated public key in accordance with official operations copied into the sesame background, after saving, sesame will generate a new public key, click Copy, save to our public key file, and then upload to the space to the PHP call.
$request->setscene ("test");
$request->setchannel ("APPPC");
$request->setplatform ("Zmop");
$request->setidentitytype ("2")//Necessary parameters
//structuring Authorized Business Entry identification number, name, certificate type; The business parameters in Chapter 4 describe Identity_param "
$request->setidentityparam (" {\ certno\ ": \" $certNo \ ", \" certtype\ ": \" Identity_ Card\ ", \" name\ ": \" $name \ "}");
$request->setidentityparam ("{\" certno\ ": \" $certNo \ "," certtype\ ": \" identity_card\ ", \" name\ ": \" $name \ ", \" Mobileno\ ": \" $mobile \ "}");
Construct business parameter extension parameters "business entry parameter description in Chapter 4 Biz_params"
$request->setbizparams ("{\ auth_code\": \ "m_h5\", \ "channeltype\": \ " App\ ", \" state\ ": \" $uid \ "}");
After the authorization succeeds, will jump to our set callback address, this callback address get parameter, has a param parameter, must use the decryption function in the SDK, after decrypting, can obtain the customer openi_id,
All right, after you get this open_id, save it to the database, and the authorization is complete.
Second step,
According to the authorized open_id, get sesame points, this SDK in the example, can run up ...
The most important thing is the 1th.
The above is a small set to introduce the PHP sesame Credit access to the attention, I hope to help you, if you have any questions please give me a message, small series will promptly reply to everyone. Here also thank you very much for the cloud Habitat Community website support!