# Create Account

Create an individual customer account by passing the required parameters along with the account settings.

<mark style="color:green;">`POST`</mark> `/api/account/v1/createaccount`

Upon successful request, the customer's account number will be generated and included in the response payload.&#x20;

{% hint style="info" %}
The `createaccount` endpoint creates a customer account only without adding additional customer profile information.
{% endhint %}

**Headers**

| Name                                            | Value                |
| ----------------------------------------------- | -------------------- |
| Content-Type<mark style="color:red;">\*</mark>  | `application/json`   |
| Authorization<mark style="color:red;">\*</mark> | `Bearer <token>`     |
| Request-Reference                               | `{unique-reference}` |

**Body**

<table data-full-width="false"><thead><tr><th width="213">Name</th><th width="175">Data Type (length)</th><th width="105" data-type="checkbox">Required</th><th>Description</th></tr></thead><tbody><tr><td><code>customerID</code></td><td>string <a data-footnote-ref href="#user-content-fn-1"><em>(10)</em></a></td><td>true</td><td>The identifier of an existing customer Individual. <br><br><em><mark style="color:orange;">This is not the customers Guid</mark></em></td></tr><tr><td><code>accountName</code></td><td>string <a data-footnote-ref href="#user-content-fn-1"><em>(250)</em></a></td><td>true</td><td>The customer's account name</td></tr><tr><td><code>referenceNumber</code></td><td>string <a data-footnote-ref href="#user-content-fn-1"><em>(50)</em></a></td><td>false</td><td>Reference number for the account. <br><br><br><em><mark style="color:orange;">This should be passed as a unique value which can be mapped to the customer's account number on the CBA an external account.</mark></em></td></tr><tr><td><code>accountType</code></td><td>integer</td><td>false</td><td><p>Type of account. <br><br>The enumerations are: </p><p><code>1</code> = Saving (Default),</p><p><code>2</code> = Current</p></td></tr><tr><td><code>accountStatus</code></td><td>integer</td><td>false</td><td><p>Status of the account.<br><br>The enumerations are: </p><p><code>1</code> = Active (Default),</p><p><code>2</code> = Dormant,<br><code>3</code> = Closed,<br><code>4</code> = PND (Post No Debit),<br><code>5</code> = PNC (Post No Credit),<br><code>6</code> = Inactive,<br><code>7</code> = Frozen<br></p></td></tr><tr><td><code>branchCode</code></td><td>string <a data-footnote-ref href="#user-content-fn-1"><em>(3)</em></a></td><td>true</td><td>The customer's bank account branch code. <br><br><em><mark style="color:orange;">The branch code must be active and exist on the CBA Portal.</mark></em></td></tr><tr><td><code>productCode</code></td><td>string <a data-footnote-ref href="#user-content-fn-1"><em>(3)</em></a></td><td>true</td><td>The customer's savings/current account product code.<br><br><em><mark style="color:orange;">The product code must be active and exist on the CBA Portal.</mark></em></td></tr><tr><td><code>accountOfficerStaffID</code></td><td>string <a data-footnote-ref href="#user-content-fn-1"><em>(3)</em></a></td><td>true</td><td>Account officer's staff ID. <br><br><em><mark style="color:orange;">The account officer code must be active and exist on the CBA Portal. CBA setup already comes with a default account officer if you don't have one.</mark></em></td></tr><tr><td><code>accountTierLevel</code></td><td>integer</td><td>false</td><td><p>Account tier level.<br><br>The enumerations are: </p><p><code>1</code> = Tier 1 (default),</p><p><code>2</code> = Tier 2,<br><code>3</code> = Tier 3</p></td></tr><tr><td><code>accessLevel</code></td><td>integer</td><td>false</td><td>The customer's access level enables restriction of balance and transaction amounts when viewed by users with lower access levels on the CBA portal.<br><br><em>Access levels range from <code>1</code> to <code>5</code></em> </td></tr><tr><td><code>enableEmailNotification</code></td><td>boolean</td><td>false</td><td>This enable the system to send email notifications to customers</td></tr><tr><td><code>enableSMSNotification</code></td><td>boolean</td><td>false</td><td>This enable the system to send SMS notifications to customers</td></tr><tr><td><code>statementDeliveryMode</code></td><td>integer</td><td>false</td><td><p>Mode of statement delivery (e.g., 1 for email)<br><br>The enumerations are: </p><p><code>1</code> = Handpicked,</p><p><code>2</code> = Email,<br><code>3</code> = Postage</p></td></tr><tr><td><code>statementDeliveryFrequency</code></td><td>integer</td><td>false</td><td><p>Frequency of statement delivery (e.g., 1 for monthly)<br><br>The enumerations are: </p><p><code>1</code> = Weekly</p><p><code>2</code> = Monthly</p></td></tr><tr><td><code>minimumBalanceRequired</code></td><td>integer</td><td>false</td><td>Minimum balance required for the account</td></tr><tr><td><code>categoryOfAccount</code></td><td>integer</td><td>false</td><td><p>Category of account.<br><br>The enumerations are: </p><p><code>1</code> = Bank Staff,</p><p><code>2</code> = Bank Director,<br><code>3</code> = Other Customers,<br><code>4</code> = Private,<br><code>5</code> = Public</p></td></tr><tr><td><code>sectorCode</code></td><td>string</td><td>false</td><td><p>Sector code of customer's work type. <br><br>The enumerations are: </p><p>40100 = Agriculture, Forestry, and Fishing </p><p>40200 = Mining and Quarrying 40300 = Manufacturing </p><p>40500 = Real Estate Activities 40700 = General Commerce 40800 = Transportation and Storage </p><p>40900 = Finance and Insurance 41000 = General </p><p>41200 = Governments </p><p>41300 = Water Supply, Sewage, Waste Management, and Remediation Activities </p><p>41400 = Construction </p><p>41500 = Information and Communication </p><p>41600 = Professional, Scientific, and Technical Activities </p><p>41700 = Administrative and Support Service Activities </p><p>41800 = Education </p><p>41900 = Human Health and Social Work Activities </p><p>42000 = Arts, Entertainment, and Recreation</p><p>42100 = Activities of Extra-Territorial Organizations and Bodies </p><p>42200 = Power and Energy 42300 = Capital Market </p><p>42400 = Oil and Gas</p></td></tr><tr><td><code>refereeInformation.referee1CustomerID</code></td><td>string (8)</td><td>false</td><td>Referee 1's customer ID: This is an individual customer's ID already in the system.</td></tr><tr><td><code>refereeInformation.referee2CustomerID</code></td><td>string (8)</td><td>false</td><td>Referee 2's customer ID: This is an individual customer's ID already in the system.</td></tr></tbody></table>

Here is an example request and response with a sample payload sent to the endpoint in Curl format.

<details>

<summary>Sample Request</summary>

```json
curl --location -g '{{baseurl}}/api/account/v1/createaccount' \
--header 'Content-Type: application/json' \
--header 'Authorization: bearer {token}' \
--header 'request-reference: {unique_reference}' \
--data '{
    "customerID": "00002109",
    "accountName": " ",
    "referenceNumber": "",
    "accountType": 1,
    "accountStatus": 1,
    "branchCode": "101",
    "productCode": "301",
    "accountOfficerStaffID": "ST1311",
    "accountTierLevel": 2,
    "accessLevel": 5,
    "enableEmailNotification": true,
    "enableSMSNotification": true,
    "statementDeliveryMode": 1,
    "statementDeliveryFrequency": 1,
    "minimumBalanceRequired": 0,
    "categoryOfAccount": 3,
    "sectorCode": "40100",
    "refereeInformation": {
        "referee1CustomerID": "00002110",
        "referee2CustomerID": "00002111"
    }
}'
```

</details>

**Response**

{% tabs %}
{% tab title="200" %}

```json
{
  "status": true,
  "message": "string",
  "data": {
    "id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
    "accountNumber": "string"
  }
}
```

{% endtab %}
{% endtabs %}

[^1]: This is the maximum number of characters allowed.
