> For the complete documentation index, see [llms.txt](https://apidoc.247express.vn/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://apidoc.247express.vn/english-1.0.6/customer/create-client-hub.md).

# Create client hub

## Address

For addresses with a **3-level structure** (Province/City, District, Ward/Commune — based on Vietnam’s administrative divisions **before July 1, 2025**), provide the following fields:

* **ProvinceName**: Recipient’s province/city name.
* **DistrictName**: Recipient’s district name.
* **WardName**: Recipient’s ward/commune name.

For addresses with a **2-level structure** (Province/City, Ward/Commune — based on Vietnam’s administrative divisions **from July 1, 2025**), provide the following fields:

* **ProvinceName**: Recipient’s province/city name.
* <mark style="color:red;">**DistrictName**</mark><mark style="color:red;">: leave null.</mark>
* **WardName**: Recipient’s ward/commune name.

## CustomerInsertClientHub

<mark style="color:green;">`POST`</mark> `/Api/Customer/CustomerInsertClientHub`

#### Request Body

| Name                                           | Type   | Description                                                                                          |
| ---------------------------------------------- | ------ | ---------------------------------------------------------------------------------------------------- |
| Address<mark style="color:red;">\*</mark>      | string | Customer's Addresss following Apartment number/Street name, Ward name, District name, Province name. |
| ContactName<mark style="color:red;">\*</mark>  | string | Contact name                                                                                         |
| ContactPhone<mark style="color:red;">\*</mark> | string | Contact phone                                                                                        |
| ProvinceName<mark style="color:red;">\*</mark> | string | Province name                                                                                        |
| DistrictName<mark style="color:red;">\*</mark> | string | District name                                                                                        |
| WardName                                       | string | Ward name                                                                                            |
| CusWarehouseID                                 | string | ID of Shop/WareHouse                                                                                 |
| CusWarehouseName                               | String | Name of Shop/WareHouse                                                                               |

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

```
{
    "HubInfo": {
        "Address": "HH1, Yên Hòa, Cầu Giấy, Hà Nội",
        "WardID": "CYGYHO",
        "ClientHubID": "248",
        "ContactName": "Nguyễn Thành Trung",
        "ContactPhone": "0986226622",
        "DistrictID": "CGY",
        "IsMain": "true",
        "ProvinceID": "HNI",
        "CustomerID": "15",
        "Status": "Init",
        "StatusName": "Chờ duyệt",
        "CusWarehouseName: "Chi nhánh HN1"
    },
    "Errors": [],
    "ErrorMessage": ""
}
```

{% endtab %}
{% endtabs %}

### Example

```
{
    "HubInfo": 
	{
        "Address": "326 Võ Văn Kiệt, Phường Cầu Ông Lãnh, Hồ Chí Minh",
        "ContactName": "Nguyễn Văn A",
        "ContactPhone": "0909123456",
        "ProvinceName": "Thành phố Hồ Chí Minh",
        "WardName": "Phường cầu ông lãnh",
        "CusWarehouseID": "30984",
        "CusWarehouseName": "Chi nhánh số 3"
    }
}
```
