> ## Documentation Index
> Fetch the complete documentation index at: https://docs.abbyy.com/llms.txt
> Use this file to discover all available pages before exploring further.

# 事業部門を作成

> v2/dataset/businessunits POST メソッドを使用して、region とユニットの詳細を指定し、FlexiCapture for Invoices Cloud API で事業部門のリストを作成します。

事業部門のリストを作成します。事業部門とは、請求書を受け取る会社、またはその会社内の部門を指します。事業部門は、請求書データや税率、その他のパラメーターをチェックするためのルールを決定する際に使用されます。

<div id="http-request">
  ## HTTP リクエスト
</div>

```http theme={null}
POST https://api-{location-id}.flexicapture.com/v2/dataset/businessunits
```

`{location-id}` を[対応ロケーション](/ja/flexi-capture/cloud/cloud-f-cfor-invoices-api#icaas-supported-countries)に置き換えてください。

<div id="request-body">
  ## リクエスト本文
</div>

リクエスト本文は、次の構造になっています。

```json theme={null}
{
  "region": "US",
  "units": [
    {
      "external_id": "string",
      "name": [
        "string"
      ],
      "street": [
        "string"
      ],
      "city": [
        "string"
      ],
      "state": [
        "string"
      ],
      "zip": [
        "string"
      ],
      "country_code": "string",
      "vat": [
        "string"
      ]
    }
  ]
}
```

| フィールド   | 型                                      | 説明                |
| ------- | -------------------------------------- | ----------------- |
| `model` | body, object(CreateBusinessUnitsModel) | 必須。地域の事業部門のリストです。 |

<div id="createbusinessunitsmodel">
  ### CreateBusinessUnitsModel
</div>

| フィールド     | 型                         | 説明                                                        |
| --------- | ------------------------- | --------------------------------------------------------- |
| `region`  | string                    | 必須。事業部門の地域。対応地域: US: USA、AU: オーストラリア、EU: 欧州連合加盟国、CA: カナダ。 |
| `units[]` | object(BusinessUnitModel) | 必須。事業部門のリストです。                                            |

<div id="businessunitmodel">
  ### BusinessUnitModel
</div>

| Field          | 型      | 説明                             |
| -------------- | ------ | ------------------------------ |
| `external_id`  | string | 必須。外部 ID。                      |
| `name[]`       | string | 必須。事業部門名。                      |
| `street[]`     | string | 任意。事業部門の住所。                    |
| `city[]`       | string | 任意。事業部門の市区町村。                  |
| `state[]`      | string | 任意。事業部門の州。                     |
| `zip[]`        | string | 任意。事業部門の郵便番号。                  |
| `country_code` | string | 必須。ISO 3166-1 alpha-2 形式の国コード。 |
| `vat[]`        | string | 任意。納税者 ID。                     |

<div id="response">
  ## レスポンス
</div>

成功すると、サーバーは HTTP ステータス `204 No Content` を返します。
