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

# Box Doc Gen

export const MultiRelatedLinks = ({sections = []}) => {
  if (!sections || sections.length === 0) {
    return null;
  }
  return <div className="space-y-8">
      {sections.map((section, index) => <RelatedLinks key={index} title={section.title} items={section.items} />)}
    </div>;
};

export const RelatedLinks = ({title, items = []}) => {
  const getBadgeClass = badge => {
    if (!badge) return "badge-default";
    const badgeType = badge.toLowerCase().replace(/\s+/g, "-");
    return `badge-${badge === "ガイド" ? "guide" : badgeType}`;
  };
  if (!items || items.length === 0) {
    return null;
  }
  return <div className="my-8">
      {}
      <h3 className="text-sm font-bold uppercase tracking-wider mb-4">{title}</h3>

      {}
      <div className="flex flex-col gap-3">
        {items.map((item, index) => <a key={index} href={item.href} className="py-2 px-3 rounded related_link hover:bg-[#f2f2f2] dark:hover:bg-[#111827] flex items-center gap-3 group no-underline hover:no-underline border-b-0">
            {}
            <span className={`px-2 py-1 rounded-full text-xs font-semibold uppercase tracking-wide flex-shrink-0 ${getBadgeClass(item.badge)}`}>
              {item.badge}
            </span>

            {}
            <span className="text-base">{item.label}</span>
          </a>)}
      </div>
    </div>;
};

export const Link = ({href, children, className, ...props}) => {
  const localizedHref = localizeLink(href);
  return <a href={localizedHref} className={className} {...props}>
      {children}
    </a>;
};

<Warning>
  Doc Gen APIは、Enterprise Advancedアカウントでのみ使用できます。
</Warning>

Box Doc Genを使用すると、採用通知書、売買契約書、請求書、契約書などのビジネスドキュメントを生成できます。BoxにアップロードされたBox Doc Genテンプレートに基づいた、Box Doc Gen APIを使用して動的に入力できるデータフィールドを含むドキュメントを生成できます。

<Note>
  Box Doc Genでは、Box Doc Genテンプレートの使用時に英語のテンプレートタグを利用する機能のみがサポートされています。お客様には、Box Doc Genがご希望の言語の要件をサポートしているかどうかをテストおよび確認することをお勧めします。
</Note>

## 前提条件

Box Doc Genを使用するには、ドキュメントテンプレートの作成に必要になるため、Microsoft Wordへのアクセス権限が必要です。Box Doc Genアドインを利用してコード不要のエクスペリエンスを実現するか、Word内でタグ付きスクリプトを適用してドキュメントを準備することができます。

<Note>
  Box Doc Genは、ビジネスドキュメントの動的な生成を容易にすることを目的としていますが、Boxでは、ユーザーのMicrosoft Wordに対するアクセス権限を制御していないことに注意してください。ユーザーは、ドキュメントテンプレートを効果的に作成するために必要なMicrosoft Wordに対する権限やアクセス権限があることを確認する必要があります。
</Note>

## Box Doc Gen APIの機能

Box Doc Gen APIを使用すると、以下のことが可能です。

* ドキュメントをBox Doc Genテンプレートとして設定する。
* Boxに保存したBox Doc Genテンプレートに基づいてドキュメントを生成する。
* Box Doc Genテンプレートやドキュメント生成ジョブの詳細を調査する。

## Box Doc Gen APIバージョン

Box Doc Gen APIはBox APIバージョン`2025.0`でリリースされました。Box Doc Gen APIのエンドポイントに対するすべてのAPIリクエストでは、`box-version`ヘッダーを`2025.0`に設定して、有効なAPIバージョンを指定する必要があります。

詳細については、<Link href="/guides/api-calls/api-versioning-strategy">APIのバージョン戦略</Link>を参照してください。

## Box Doc Genのワークフロー

<Frame>
  <img src="https://mintcdn.com/box/_tECS-SYBYV9K-kZ/images/guides/docgen/docgen-workflow.png?fit=max&auto=format&n=_tECS-SYBYV9K-kZ&q=85&s=d6f7b9b4c9ea191b90c81b778256c845" alt="Box Doc Genのワークフローを表すフロー図" width="1596" height="490" data-path="images/guides/docgen/docgen-workflow.png" />
</Frame>

1. Box Doc Genテンプレートを作成します。
   * [Microsoft Word用Doc Genアドイン][template-addin]を使用して、コードを使用せずにテンプレートを作成する。
   * [Doc Genのタグ付きスクリプト][tagging-script]を利用してテンプレートを作成することも可能。

2. Box Doc Gen UIを使用して[Boxにテンプレートを追加][upload-template]します。この時点では、以下のことが可能です。
   * Box内の既存のファイルをDoc Genテンプレートとして設定する。
   * ドキュメントを作成またはアップロードして、Box Doc Genテンプレートとして設定する。

3. Box Doc Gen APIを使用して<Link href="/guides/docgen/generate-document">ドキュメントを生成</Link>する。

[template-addin]: https://support.box.com/hc/en-us/articles/36587535449747-Installing-Box-Doc-Gen-Add-in

[template-tags]: https://support.box.com/hc/en-us/articles/36151895655059-Creating-A-Box-Doc-Gen-Template-Manually

[json-template]: https://support.box.com/hc/en-us/articles/36148012877843-Creating-a-Box-Doc-Gen-Template-using-JSON-data

[tagging-script]: https://support.box.com/hc/en-us/articles/36149723736723-Template-tags-reference

[upload-template]: https://support.box.com/hc/en-us/articles/36587432368275-Managing-Box-Doc-Gen-Templates-in-Relay

<RelatedLinks
  title="関連するガイド"
  items={[
{ label: translate("Get started with Box Doc Gen"), href: "/guides/docgen/docgen-getting-started", badge: "GUIDE" },
{ label: translate("Box Doc Gen templates"), href: "/guides/docgen/docgen-templates", badge: "GUIDE" },
{ label: translate("Box Doc Gen jobs"), href: "/guides/docgen/docgen-jobs", badge: "GUIDE" },
{ label: translate("Mark file as Box Doc Gen template"), href: "/guides/docgen/mark-template", badge: "GUIDE" },
{ label: translate("Generate documents"), href: "/guides/docgen/generate-document", badge: "GUIDE" }
]}
/>
