Skip to main content

CreateCardholder API

Endpoints

Live POST https://pay.onlinepay.ai/card/createCardholder

Sandbox POST https://testpay.onlinepay.ai/card/createCardholder

Request Parameters

Basic Information

ParameterTypeRequiredDescription
merNoIntegerYesMerchant Number, Unique identifier assigned to the merchant by the onlinepay payment platform when registering with onlinepay
firstNameStringYesFirst Name (max 50 characters)
lastNameStringYesLast name (max 50 characters)
cityStringYesCity of residence (bill) (max 100 characters)
countryStringYesrefer to Country info,such as China : CN
addressStringYesBilling address 1 (max 128 characters)
zipcodeStringYesPostal Code (max 20 characters)
stateStringYesState Name (max 100 characters)
emailStringYesemail (max 100 characters)
telStringYesphone (max 20 characters)
birthdayStringYesBirthday (yyyy-MM-dd)
genderStringYes1:male 0:female
telCodeStringYesrefer to Country info,such as China : CN
idType1StringYes01:idCard(nationality is China) 02:passport(country is not China)
idCard1StringYesID number (max 50 characters)
idType2StringNorequired when nationality is not China. 03: Hong Kong, Macao and Taiwan ID card. 06: Other types of personal valid documents 06: Other types of personal valid documents
idCard2StringNoID number (max 50 characters) ,required when nationality is not China.
photoFrontId1StringYesfront photo fid of idTeype1,result of Upload File
photoBackId1StringYesback photo fid of idType1,result of Upload File
photoFrontId2StringNofront photo fid of idType2,result of Upload File
photoBackId2StringNoback photo fid of idType2,result of Upload File
signStringYesSignature, MD5(merNo+PrivateKey) or RSA

Example Request

{
"merNo": "104001001",
"firstName": "test2",
"lastName": "test",
"city": "city1",
"country": "CN",
"address": "adress1",
"zipcode": "000000",
"state": "state1",
"email": "[email protected]",
"tel": "123456789",
"birthday": "2000-01-01",
"gender": "1",
"telCode": "86",
"idType1": "01",
"idCard1": "331000000000000000",
"photoFrontId1": "1727235173391.png",
"photoBackId1": "1727235173391.png",
"sign": "e8b6b0b9f0b0f8b0b8b0a0b0c0d0e0f"
}

Responses Body

ParameterTypeRequiredDescription
codestringYesIf the value is 00000, it will return success, other please refer to Error Code
messagestringYesInterface returns description
datastringYesapplyOrderNo: onlinePay apply order number

Example Responses

{
"code":"00000",
"message":"SUCCESS",
"data":"CAD0240927153321448"
}