5.4.4.4 User Registration API

After a participant has successfully joined in a FISCO BCOS (FISCO) DApp, his/her off-BSN system can invoke this interface to generate the user account and user address to execute smart contract transactions.

1. Interface address:

https://PCNGatewayAddress/api/fiscobcos/v1/user/register

2. Call Method: POST

3. Signature algorithm: required and refer to Section 5.4.4.1

4. Call parameters

No. Field name Field Type Required Remarks
1 Header header Map Y
2 Body body Map Y
3 Signature Value mac String Y
header
1 user unique ID userCode String Y
2 DApp unique ID appCode String Y
body
1 user name userId String Y Registered user name

Example:

{
"header":{"appCode":"CL1881038873220190902114314","userCode":"newuser"},
"body":
{
“userId”:”abc”
},
"mac":"MEQCIBRhaM2szckWl9N9qcqnaYXOXGQw7SfII9DlRvxcI3YVAiBt4XeNs+EUjhBNSr3IjLRPZucsuGHxfjt9RiaNIQS8cA=="}

5. Response parameters

No. Field name Field Type Required Remarks
1 Header header Map Y
2 Body body Map Y
3 Signature Value mac String Y
header
1 Response ID code int Y 0: authentication successful -1: authentication failed
2 Response Message msg String N if code=0 then can be null
body
1 User information data []string N If code is not 0, then leave blank
data
1 User ID userId String Y
2 User Address userAddress String Y

Example:

{
  "header": {
    "code": 0,
    "msg": "Transaction Successful"
  },
  "mac": "MEQCIEI5VKMyJUXls2Hf8TLoPXjZLT4/L2wyXoddgTnZdqRsAiBxEBMeCOZ8M97OCRUAMZNMcL974vhzjOS/tk8/wbgbsA==",
  "body": {
    "userId": "100003",
    "userAddress": "0x14647a48303b5e1c77934583883ebc327ba3b297"
  }
}
© 2019-2021 Red Date (Hong Kong) Technology Limited. all right reserved,powered by GitbookFile Modify: 2021-06-01 18:41:39

results matching ""

    No results matching ""

    results matching ""

      No results matching ""