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

# 企業作成API：ベンダーKYBエンティティの登録

> KYBセッションの実行前にDiditの企業（KYB）エンティティを事前登録します。外部データベースからの一括オンボーディングや取引モニタリング用の登録に利用できます。



企業作成プロンプト
        プロンプトをクリップボードにコピー



      
      

\<pre>

\`Goal: Pre-create a Didit Business (KYB) entity by vendor_data before any KYB session runs.

Endpoint: POST https://verification.didit.me/v3/businesses/create/
Auth header: x-api-key: <DIDIT_API_KEY>
Content-Type: application/json

Request body fields:
\- vendor_data (string, REQUIRED) — your unique identifier. Free-form string, NOT a UUID. Must be unique among non-deleted businesses for the app. Normalised lowercase + whitespace trim ("COMPANY-1" and "company-1" collide).
\- display_name (string, nullable) — friendly display name shown in Console (takes precedence over legal_name).
\- legal_name (string, nullable)
\- registration_number (string, nullable)
\- country_code (string, nullable) — country of incorporation, ISO 3166-1 alpha-2 (e.g. "GB", "US").
\- region (string, nullable) — ISO 3166-2 subdivision code.
\- status (enum) — "ACTIVE" | "FLAGGED" | "BLOCKED" (VendorBusinessStatusChoices). Defaults to "ACTIVE".
\- metadata (object, nullable) — arbitrary JSON.

curl:
curl -X POST 'https://verification.didit.me/v3/businesses/create/' \
-H 'x-api-key: YOUR_API_KEY' \
-H 'Content-Type: application/json' \
-d '{"vendor_data": "company-456", "legal_name": "New Corp Ltd", "country_code": "US"}'

Response 201: full BusinessDetailItem (same shape as GET /v3/businesses/{vendor_data}/). Includes didit_internal_id (UUID), session_count=0, metadata, comments=[], created_at, updated_at. See /reference/data-models.

Failure modes (envelope {"detail": "..."} for auth):
\- 400 — validation errors keyed by field. Common cases:
\{ "vendor_data": ["A business with this vendor_data already exists."] }  // NOT idempotent — use PATCH /v3/businesses/{vendor_data}/ to update.
\{ "vendor_data": ["This field is required."] }
\{ "metadata": ["Metadata must be a JSON object."] }
\- 401 — missing/invalid x-api-key.
\- 403 — lacks create:businesses.
\- 429 — rate-limited.

Upsert pattern (NOT idempotent on vendor_data):
GET /v3/businesses/{vendor_data}/  → on 404, POST /v3/businesses/create/; on 200, PATCH /v3/businesses/{vendor_data}/.

Notes:
\- Registry-derived fields (legal_name, registration_number, country_code) can be seeded here but will be OVERWRITTEN by the first approved Business Verification (KYB) session's registry data.
\- last_activity_at is set at the moment of creation.

For end-to-end Didit integration, paste in the full prompt at /integration/integration-prompt.`

\</pre>



      
      

貼り付け先

## 概要法人確認 (KYB) セッションを実行する前に、[法人エンティティ](https://docs.didit.me/ja/entities/businesses/overview.md)を明示的に作成します。## 使用するケース- 最初の法人確認 (KYB) セッションの前に、**メタデータを事前登録**する場合(パートナー、レベル、社内識別子など)。
- 既存の企業一覧を保有した状態で、別のKYBベンダーから**移行**する場合。
- **取引のみ**の登録。オフラインのプロセスで確認済みの企業について取引を送信する場合。## 注意事項- `vendor_data`は必須で、アプリケーションごとに一意である必要があります。重複すると競合エラーが返されます。更新するには[`PATCH /v3/businesses/{vendor_data}/`](https://docs.didit.me/ja/management-api/businesses/update)を使用してください。
- 登記由来のフィールド(`legal_name`、`registration_number`、`country_code`)は事前登録できますが、最初に承認済みとなった法人確認 (KYB) セッションの登記データによって**上書き**されます。
- `country_code`がアプリケーションの[危険国](https://docs.didit.me/ja/entities/businesses/blocklist.md#危険国)リストに該当する場合、企業は`BLOCKED`ステータスで作成されます。
- `business.data.updated`を発行します。## 権限役割に`create:businesses`が付与されている必要があります。## 関連情報- [企業データモデル](https://docs.didit.me/ja/entities/businesses/data-model.md)
- [ベンダーデータの紐付け](https://docs.didit.me/ja/entities/vendor-data-linking.md)
- [企業の運用](https://docs.didit.me/ja/entities/businesses/operations.md)


## OpenAPI

````yaml ja/openapi-25.json POST /v3/businesses/create/
openapi: 3.0.0
info:
  version: 3.0.0
  title: Didit Verification API
  description: 本人確認API。x-api-keyヘッダーで認証します。
servers:
  - url: https://verification.didit.me
security: []
tags: []
paths:
  /v3/businesses/create/:
    post:
      tags:
        - Businesses
      summary: 企業を作成
      description: >-
        KYBセッションを*伴わずに*[企業](/entities/businesses)を事前作成します。すべてのフィールドは任意ですが、`vendor_data`は必ず送信してください。これがないと、レコードをセッションや取引に紐付けることができません。指定した場合、`vendor_data`は削除されていない企業の間で一意である必要があります(完全一致。重複した場合は400が返されます)。冪等ではありません。
      operationId: create_business
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                vendor_data:
                  type: string
                  nullable: true
                  description: >-
                    この企業に対するお客様独自の識別子です（自由形式の文字列で、UUIDではありません）。任意ですが、指定を強く推奨します。指定する場合は、アプリケーション内の削除されていない企業の間で一意である必要があり、送信されたとおりに完全一致で照合されます。
                display_name:
                  type: string
                  nullable: true
                  maxLength: 255
                  description: コンソールに表示されるわかりやすい表示名（UI表示では`legal_name`より優先されます）。
                legal_name:
                  type: string
                  nullable: true
                  maxLength: 255
                  description: 企業の正式な法人名。
                registration_number:
                  type: string
                  nullable: true
                  maxLength: 100
                  description: 法人の登記番号または設立番号。
                country_code:
                  type: string
                  nullable: true
                  maxLength: 10
                  description: '設立国（ISO 3166-1 alpha-2、例: `GB`、`US`）。'
                status:
                  type: string
                  enum:
                    - ACTIVE
                    - FLAGGED
                    - BLOCKED
                  default: ACTIVE
                  description: 初期のライフサイクルステータス。デフォルトは`ACTIVE`です。
                metadata:
                  type: object
                  nullable: true
                  description: 企業に付与する任意のJSONオブジェクト。デフォルトは`{}`です。
            examples:
              Basic:
                summary: 推奨される最小値
                value:
                  vendor_data: company-456
                  legal_name: New Corp Ltd
                  country_code: US
              Full:
                summary: すべてのフィールド
                value:
                  vendor_data: company-789
                  display_name: New Corp
                  legal_name: New Corp International Ltd
                  registration_number: '98765432'
                  country_code: DE
                  status: ACTIVE
                  metadata:
                    industry: fintech
                    tier: enterprise
      responses:
        '201':
          description: 企業を作成しました。企業の完全なレコードが返されます(Get Businessと同じ形式)。
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BusinessDetailItem'
              examples:
                Created:
                  value:
                    didit_internal_id: a1b2c3d4-e5f6-4890-abcd-ef1234567890
                    vendor_data: company-456
                    display_name: null
                    legal_name: New Corp Ltd
                    registration_number: null
                    country_code: US
                    effective_name: New Corp Ltd
                    status: ACTIVE
                    session_count: 0
                    approved_count: 0
                    declined_count: 0
                    in_review_count: 0
                    features: {}
                    features_list: []
                    last_session_at: null
                    last_activity_at: '2026-03-15T10:30:00Z'
                    first_session_at: null
                    tags: []
                    created_at: '2026-03-15T10:30:00Z'
                    metadata: {}
                    updated_at: '2026-03-15T10:30:00Z'
        '400':
          description: >-
            無効なリクエストボディ。主な原因は、重複した`vendor_data`、不明な`status`、または不正な形式の`metadata`です。
          content:
            application/json:
              examples:
                Duplicate:
                  value:
                    vendor_data:
                      - A business with this vendor_data already exists.
                Bad status:
                  value:
                    status:
                      - >-
                        Invalid status. Valid options are: ACTIVE, FLAGGED,
                        BLOCKED
                Bad metadata:
                  value:
                    metadata:
                      - Metadata must be a JSON object.
        '403':
          description: >-
            APIキーがない、無効、または失効しています。または、そのキーではこのアプリケーションの企業を作成できません。キーがない場合は`403`を返し、誤った、失効した、または期限切れのキーの場合は`401`を返します。
          content:
            application/json:
              examples:
                Forbidden:
                  value:
                    detail: You do not have permission to perform this action.
        '429':
          description: レート制限を超過しました。間隔を空け、`Retry-After`で示された時間が経過してから再試行してください。
          content:
            application/json:
              examples:
                Rate limited:
                  value:
                    detail: Request was throttled. Expected available in 30 seconds.
      security:
        - ApiKeyAuth: []
      x-codeSamples:
        - lang: curl
          label: curl
          source: |-
            curl -X POST 'https://verification.didit.me/v3/businesses/create/' \
              -H 'x-api-key: YOUR_API_KEY' \
              -H 'Content-Type: application/json' \
              -d '{"vendor_data": "company-456", "legal_name": "New Corp Ltd", "country_code": "US"}'
        - lang: python
          label: Python
          source: |-
            from didit import Didit

            # Reads DIDIT_API_KEY.
            client = Didit()

            result = client.businesses.create(
                vendor_data="company-456",
                legal_name="New Corp Ltd",
                country_code="US",
            )
            print(result)
        - lang: javascript
          label: Node.js
          source: |-
            import Didit from "@didit-protocol/sdk-node";

            // Reads DIDIT_API_KEY.
            const didit = new Didit();

            const result = await didit.businesses.create({
              vendor_data: "company-456",
              legal_name: "New Corp Ltd",
              country_code: "US",
            });
            console.log(result);
        - lang: go
          label: Go
          source: "ctx := context.Background()\n// Reads DIDIT_API_KEY.\nclient := didit.NewClient()\n\nresult, err := client.Businesses.Create(ctx, didit.BusinessesCreateParams{\n\tVendorData:  didit.String(\"company-456\"),\n\tLegalName:   didit.String(\"New Corp Ltd\"),\n\tCountryCode: didit.String(\"US\"),\n})\nif err != nil {\n\tlog.Fatal(err)\n}\nfmt.Printf(\"%+v\\n\", result)"
        - lang: java
          label: Java
          source: >-
            import me.didit.Didit;

            import me.didit.types.BusinessesCreateParams;


            // Reads DIDIT_API_KEY.

            Didit client = new Didit();


            var result =
            client.businesses().create(BusinessesCreateParams.builder()
                    .vendorData("company-456")
                    .legalName("New Corp Ltd")
                    .countryCode("US")
                    .build());
            System.out.println(result);
        - lang: php
          label: PHP
          source: |-
            <?php

            require 'vendor/autoload.php';

            use Didit\DiditClient;

            // Reads DIDIT_API_KEY.
            $didit = new DiditClient();

            $result = $didit->businesses->create([
                'vendor_data' => 'company-456',
                'legal_name' => 'New Corp Ltd',
                'country_code' => 'US',
            ]);
            print_r($result->toArray());
        - lang: ruby
          label: Ruby
          source: |-
            require "didit"

            # Reads DIDIT_API_KEY.
            didit = Didit::Client.new

            result = didit.businesses.create(
              vendor_data: "company-456",
              legal_name: "New Corp Ltd",
              country_code: "US"
            )
            puts result.to_h
        - lang: csharp
          label: .NET
          source: >-
            using System;

            using System.Text.Json;

            using Didit;


            // Reads DIDIT_API_KEY.

            using var client = new DiditClient();


            var result = await client.Businesses.CreateAsync(new
            BusinessesCreateParams

            {
                VendorData = "company-456",
                LegalName = "New Corp Ltd",
                CountryCode = "US",
            });

            Console.WriteLine(JsonSerializer.Serialize(result));
components:
  schemas:
    BusinessDetailItem:
      type: object
      description: 企業の完全な詳細。BusinessListItemにmetadataとupdated_atを追加したものです。
      allOf:
        - $ref: '#/components/schemas/BusinessListItem'
        - type: object
          properties:
            metadata:
              type: object
              description: この企業に付加したカスタムメタデータJSON。デフォルトは`{}`です。
            updated_at:
              type: string
              format: date-time
    BusinessListItem:
      type: object
      description: 認証済みの企業。
      properties:
        didit_internal_id:
          type: string
          format: uuid
          description: この企業に対するDiditの安定した内部UUIDです。
        vendor_data:
          type: string
          nullable: true
          description: >-
            この企業に対するお客様独自の識別子です（セッション作成時に渡されたもの）。ベンダー識別子が指定されなかった場合はnullになることがあります。
        display_name:
          type: string
          nullable: true
          description: お客様が設定したカスタム表示名
        legal_name:
          type: string
          nullable: true
          description: 登記簿または手動入力による正式な法人名
        registration_number:
          type: string
          nullable: true
          description: 会社の登記番号または設立番号
        country_code:
          type: string
          nullable: true
          description: '設立国（ISO 3166-1 alpha-2、例: `GB`、`US`）。'
        effective_name:
          type: string
          nullable: true
          description: 利用可能な最適な名前：display_nameが設定されていればそれを、設定されていなければlegal_nameを使用
        status:
          type: string
          enum:
            - ACTIVE
            - FLAGGED
            - BLOCKED
          description: >-
            企業レコードのライフサイクルステータス（セッションのステータスではありません）。`ACTIVE`がデフォルトで、`FLAGGED`は手動での確認対象としてマークし、`BLOCKED`はこの`vendor_data`での新規セッションを禁止します。
        session_count:
          type: integer
          description: この企業の認証セッションの総数
        approved_count:
          type: integer
          description: 承認済みセッションの数
        declined_count:
          type: integer
          description: 却下されたセッションの数
        in_review_count:
          type: integer
          description: レビュー中のセッション数
        features:
          type: object
          description: >-
            この企業のすべてのKYBセッションを通じた、機能ごとの集計ステータスです。現在のキーは`KYB`（登記上の企業チェックのステータス）のみです。取り得る値は`Approved`、`Declined`、`In
            Review`、`Not Finished`、`Resub Requested`です。
        features_list:
          type: array
          items:
            type: object
            properties:
              feature:
                type: string
              status:
                type: string
          description: '`features`と同じデータを、`{feature, status}`オブジェクトの順序付き配列で表したもの。'
        last_session_at:
          type: string
          format: date-time
          nullable: true
          description: 直近のセッションの日時
        first_session_at:
          type: string
          format: date-time
          nullable: true
          description: 最初のセッションの日時
        last_activity_at:
          type: string
          format: date-time
          nullable: true
          description: 直近のアクティビティ(ステータス変更、セッション更新など)の日時
        tags:
          type: array
          items:
            type: object
            properties:
              uuid:
                type: string
                format: uuid
              name:
                type: string
              color:
                type: string
          description: この企業に割り当てられたタグ
        created_at:
          type: string
          format: date-time
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: x-api-key
      description: >-
        お客様のアプリケーションのAPIキーです。Business ConsoleのDevelopers -> API
        keysで取得できます。プライマリキーはフルアクセス権を持ちます。名前付きキーにはスコープを設定できます。リソースごとのアクセス権（なし、読み取り、書き込み）、一部のワークフローまたは承認済みセッションへの限定、IPアドレスのリストへの限定、有効期限の設定です。401は、キーが誤っている、失効している、または期限切れであることを意味します。403は、キーが送信されていない、キーにこのリソースやアクションへのアクセス権がない、またはIPリスト外のアドレスからリクエストが送信されたことを意味します。セッションのルートでの404は、セッションがキーのワークフローまたはステータスの対象外であることを意味します。メディアへのアクセス権がないキーでは、画像、動画、PDFのURLがnullで返されます。セッションの書き込み権限がないキーでは、セッションのリンクとトークンがnullで返されます。詳細は次を参照してください:
        https://docs.didit.me/console/api-keys

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.