Create KYC users
Use this API call to create KYC user accounts.
If your system uses sub-accounts to segregate the submissions, you need to create a KYC user for each sub-account. Once you create a KYC user for each sub-account, you can include the sub-account userId (through the onBehalf parameter) when submitting for verification so the submissions are grouped accordingly.
Parameters
| Name | Type | Description | 
|---|---|---|
| country(required) | string | 3 letter country ISO | 
| email(required) | string | Account email address | 
| companyName(required) | string | The name of your client's legal entity | 
| companyNumber(required) | string | The number of your client's legal entity | 
| firstName(required) | string - letters only | First name of your client's contact | 
| lastName(required) | string - letters only | Last name of your client's contact | 
| FCL(required) | numbers | Financial or Credit licence | 
| regulatoryNumber | numbers | Regulatory body enrollment number | 
Runnable example
POST
/createUser// api endpoint
const apiEndpoint = 'https://dev.bronid.com/createUser';
// request body
const data = {
"metadata_version": "4",
"metadata_serviceUid": "XL7ULiU6B4QE9Y2iWFZnhtMDKFN2",
"metadata_secretKey": "api_sec_NJAtNcRtUrPlf7xYDrMNP9URI-ZfN314",
"fields": {
	"country": "AUS",
	"email": "yourUserEmailAccount@email.com",
	"companyName": "Company Pty Ltd",
	"companyNumber": "123456789",
      "firstName": "Contact",
      "lastName": "Person",
      "FCL": "123456789",
      "regulatoryNumber": "123456789"
}
};
try {
  const response = await fetch(apiEndpoint, {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
    },
    body: JSON.stringify(data),
  });
  if (!response.ok) {
    const errorData = await response.json();
    console.log('error! click the results to expand them');
    console.log(JSON.stringify(errorData, null, 2));
  } else {
    const result = await response.json();
    const printResult = 'bronId API response: ' + JSON.stringify(result, null, 2);
    console.log(printResult);
  }
} catch (error) {
  console.log('Fetch error: ', error);
}