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

# ファイルカテゴリを更新

> 指定したファイルカテゴリ情報を更新します。

注意: extract_model を設定すると、このカテゴリ配下のすべてのフィールドとテーブルの抽出モデルが連鎖的に上書きされます。




## OpenAPI

````yaml /docflow-global/ja/rest-api/openapi.bundle.yaml post /api/app-api/sip/platform/v2/category/update
openapi: 3.0.0
info:
  title: DocFlow API
  description: DocFlow REST API。ファイルアップロードとファイル処理結果の取得機能を提供します。
  version: 2.8.4
  contact:
    name: TextIn
    url: https://www.textin.ai/contact?type=27&sub_type=1
servers:
  - url: https://docflow.textin.ai
security:
  - ApiId: []
    SecretCode: []
tags:
  - name: ワークスペース管理
    description: ワークスペース関連 API
  - name: ファイルカテゴリ
    description: ファイルカテゴリ関連 API
  - name: ファイルカテゴリサンプル
    description: ファイルカテゴリサンプル関連 API
  - name: スマートレビュー
    description: スマートレビュー関連 API
  - name: 廃止済み
    description: 廃止済み API
paths:
  /api/app-api/sip/platform/v2/category/update:
    post:
      tags:
        - ファイルカテゴリ
      summary: ファイルカテゴリを更新
      description: |
        指定したファイルカテゴリ情報を更新します。

        注意: extract_model を設定すると、このカテゴリ配下のすべてのフィールドとテーブルの抽出モデルが連鎖的に上書きされます。
      operationId: updateCategory
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                workspace_id:
                  type: string
                  description: ワークスペース ID
                  example: '1234567890'
                category_id:
                  type: string
                  description: ファイルカテゴリ ID
                  example: '1234567890'
                name:
                  type: string
                  description: ファイルカテゴリ名
                  example: インボイス
                  maxLength: 50
                category_prompt:
                  type: string
                  description: 分類用プロンプト
                  example: VAT インボイス。インボイスコード、インボイス番号などのフィールドを含みます。
                  maxLength: 150
                enabled:
                  $ref: '#/components/schemas/EnabledStatus'
                extract_model:
                  type: string
                  description: |
                    抽出モデル, cascades to all fields and tables when set
                    - Auto: 抽出モデルを自動でマッチング
                    - Acgpt: 高速で安定した抽出結果
                    - Acgpt-VL: VLM。シンプルな抽出に適しています（≤10 ページ）
                    - DF-M1: 複雑な文書理解に適しています
                  example: Acgpt
                  enum:
                    - Auto
                    - Acgpt
                    - Acgpt-VL
                    - DF-M1
                with_detail:
                  type: boolean
                  description: |
                    完全な詳細を返すかどうか。true の場合、子レベルのフィールド/テーブルを除くカテゴリ自身の情報を返します。
                    未設定または false の場合、code/msg のみを返します。
              required:
                - workspace_id
                - category_id
      responses:
        '200':
          description: ファイルカテゴリの更新に成功
          content:
            application/json:
              schema:
                allOf:
                  - $ref: '#/components/schemas/CodeMessage'
                  - type: object
                    properties:
                      result:
                        description: with_detail=true の場合はカテゴリ自身の情報、それ以外は null
                        type: object
                        properties:
                          id:
                            type: string
                            description: カテゴリ ID
                          name:
                            type: string
                            description: カテゴリ名
                          description:
                            type: string
                            description: カテゴリ説明
                          category_prompt:
                            type: string
                            description: 分類プロンプト
                          extract_model:
                            type: string
                            description: 抽出モデル
                          enabled:
                            type: integer
                            description: 有効化ステータス
components:
  schemas:
    EnabledStatus:
      type: integer
      description: |
        有効化ステータス
        - 0: 無効
        - 1: 有効
        - 2: 下書き
      enum:
        - 0
        - 1
        - 2
    CodeMessage:
      type: object
      properties:
        code:
          type: integer
          description: ステータスコード
          example: 200
        msg:
          type: string
          description: ステータス説明
      required:
        - code
        - msg
  securitySchemes:
    ApiId:
      type: apiKey
      in: header
      name: x-ti-app-id
    SecretCode:
      type: apiKey
      in: header
      name: x-ti-secret-code

````