Skip to content

Create Customer

Function Description

  • Create a customer under a merchant

Customer Status Description

The initial status of creating a customer is incomplete. After the merchant completes the customer information, it will be changed to pending. In the pending review status, the system reviewer can perform operations such as normal, reject, and banned on the data.

Create customer API

Request URL

  • /payee/custom/create

Request Method

  • POST

Request Parameters

The request parameters are as follows:

TIP

  1. If the customer account information is a bank account, bankcode, cardno, ibanaccount are required. If the customer account is a STCPay account, stcaccount is required.
  2. In the sandbox environment, you can use the test account to simulate the customer's review status.
  3. You can contact the system administrator to add the product name for sending OTP verification. Multiple product names are supported. The default name is the background company name.
  4. When the automatic approval function is enabled, if the customer updates stcaccount, the customer's stcaccount will be automatically create OTP send task
ParameterRequiredTypeDefault ValueDescription
name_eYstring-Customer english name, length limit 64 characters
name_aYstring-Customer arabic name, length limit 64 characters. if the customer does not have an arabic name, you can fill in the customer english name
mercustomidYstring-Merchant customer ID, requires the merchant to provide a unique ID, length limit 128 characters
identityYstring-ID number (sensitive information, encrypted with the system public key), length limit 64 characters
bankcodeNstring-Bank code
cardnoNstring-Bank account (sensitive information, encrypted using system public key), must be a number, length limit 13 to 19 characters
ibanaccountNstring-IBAN, letters and numbers, length limit 34 characters
stcaccountNstring-STCPay account (sensitive information, encrypted using system public key), supported formats:
5xxxxxxxx
9665xxxxxxxx
+9665xxxxxxxx
05xxxxxxxx
autoapprovalNnumber0Whether to enable automatic approval:
0: Disable
1: Enable
otpappnameNstring-The product name for sending OTP verification, which needs to match the background configuration. The default name is the background company name, with a length limit of 32 characters

Request Parameter Example

json
{
    "name_e":"usera",
    "name_a":"usera",
    "mercustomid":"u001",
    "identity":"z9LnjQJuvqDnaWsrLgrO1GxT2z7fww/sxNxWjrMTinFgT5dNrn1CbpRMy99qc1GnyqzlwBytZf6oa4fOQO5kHQwR4DVMRpmii81MqgAuWBQJktCG5mAgd5yzUO2kLZyHDfy5J7Y2pMyqmFzvMPiD1tIxPezgcExXEKxcPKs1tvOr+7zgTbNtnvfm1VW+BzIVmJYmaXBW4ZhEdJqz+dxdSyZIdUdbV1oc46xiuIxZOn3hxYMy0XnGjNJNT9TSW299pSSDBpVbCoWg9u4okMI222adQyikyfz+TlSsVNTHnnB8C+rf+Kjc6ZPszCdu+KTjiYOTkRlJIUbHe0bM02pOjg==",
    "bankcode":"1174c",
    "cardno":"Zh4EkxILOkTNwk4PcEerZjpmmTu6IorKDC1jpm4l3hMuEI4zWJ2pyafiTDNaIoN6VOh8ivWxJBeOD2N6uXiPwJ6qyreVMhDsYa8nHK58l2JM6BC1teG0Q61ZPknXloB6aaDgDSQetbdomggAH+cu7masFnLU+YmI1umP/p7DhePYjT69Yq3vJ2wBEUp0dVIaINB0c4uB/bapmWb3zmBcSW1To2RopXlNIggjk1qdLUtxXmaYdzkyRJbevpBHARaA/BwIm3e1/ZwO+WUETBmhci96ciPBuf/NzyhUp9UHPgNoajdAwwdN5FUEA9E1KE6uwHdWMAICy/pWzsaOjoQpOQ==",
    "ibanaccount":"1234567892"
}

Response Parameters

The response parameters are as follows:

  • Response Body
ParameterTypeDescription
customidstringSystem customer ID
mercustomidstringMerchant customer ID
name_estringCustomer english name
name_astringCustomer arabic name
identitystringID number (sensitive information, encrypted with merchant public key)
identitypicstringID card photo URL (sensitive information, encrypted using merchant public key)
signpicstringSignature photo URL (sensitive information, encrypted using merchant public key)
banknamestringBank name
bankcodestringBank code
cardnostringBank account (sensitive information, encrypted using merchant public key)
ibanaccountstringIBAN
stcaccountstringSTCPay account (sensitive information, encrypted using merchant public key)
statusnumberCustomer status
statusdescstringCustomer status description
autoapprovalnumberWhether to enable automatic approval:
0: Disable
1: Enable
otpappnamestringProduct name for sending OTP verification
demand_perfectionarrayWhat information does the user currently need to improve
created_atnumberCreation time
updated_atnumberUpdate time

响应参数示例

json
{
    "code": 200,
    "message": "Request succeeded.",
    "data": {
        "customid": "12ad4",
        "mercustomid": "u004",
        "name_e": "usera",
        "name_a": "usera",
        "identity": "s0YhJVboAqQj8kLCkTqCttAwpP39nR5VaaTy8pWFwSQDjSYei7YqZAbcoeckAD40bgliH9sSXre9PafDDpHfdkKX22X0lvJzIcpL8PGSpWQT2XloHjKxExRhiq/AgzEnwV9kq66b2hqi56O2djjzYOXOz/BpYKqvqWG7ak47OLV2hDR6r0hzhZsdvvvCeo21lMafUGd6hmf6TElqDntIfgFNTGSbxkV3kKlXnNX0hdHPmGtnfqbIuxo+yAHeJdffxA/6iHzSsW92t/bvtB9hV5ON+v4s/VpVZCRYmj0AIs9bQ+Ed+hNXtlmLuyaxfRdYVG6nl1MhVGJG0QioO4sNag==",
        "identitypic": "",
        "signpic": "",
        "bankname": "Riyad Bank",
        "bankcode": "1174c",
        "cardno": "W0jEosfhj/TfHAjjxyIaCWHZVfdwL/2rsXj4xoXzuPWZN2nKLYmlogABKjuNF9930fmyCyt3cGZD4MRgwjf8/ZZKb0HqQLAtw+rfc/2PRViXkdq4vr3iTGyH4W7MW4n0yw6rREZUf+9/R96zyqA5iky0A0kz2suAiKBQjsQGZ1PBCGYPxmzDnpolk76Bhvpm2YNgQnvRCLUQIOCIdq4Aj9rmV0MzfhilTZ3MhIe4WqW7eubFwq0+3CF484uSVemkdRYPVZ17umbCDTRENdzkTKUIZwxTxRTMfHyUr5Sx75RyBpJDzoReluIKnX9tzQ/jb+/V4Eiv39FD4l5/Zp8trA==",
        "ibanaccount": "1234567892",
        "stcaccount": "",
        "status": 4,
        "statusdesc": "2023-06-15 06:12:54",
        "autoapproval": 1,
        "otpappname": "test",
        "demand_perfection": [
            "identitypic"
        ],
        "created_at": 1686809574,
        "updated_at": 1686809574
    },
    "sensitiveFields": [
        "identity",
        "identitypic",
        "signpic",
        "stcaccount",
        "cardno"
    ],
    "requestId": "91A8340E7AEE8EC99D06EB46DF92A19F"
}