> ## Documentation Index
> Fetch the complete documentation index at: https://dify-6c0370d8-fix-template-upload-size-guidance.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# 子チャンク一覧を取得

> 特定の親チャンク配下の子チャンクのページネーションリストを返します。



## OpenAPI

````yaml /ja/api-reference/openapi_service.json get /datasets/{dataset_id}/documents/{document_id}/segments/{segment_id}/child_chunks
openapi: 3.0.1
info:
  description: >-
    Dify アプリケーションとナレッジベースのための REST API です。アプリケーション系エンドポイントはアプリの API
    キーで、ナレッジ系エンドポイントはナレッジベースの API キーで認証します。
  title: Dify サービス API
  version: 1.0.0
servers:
  - description: Dify サービス API のベース URL です。セルフホスト環境では、独自の API ベース URL に置き換えてください。
    url: https://{api_base_url}
    variables:
      api_base_url:
        default: api.dify.ai/v1
        description: API ベース URL のホストとパス（`https://` を除く）。
security:
  - ApiKeyAuth: []
tags:
  - description: チャットメッセージとインタラクションに関連する操作です。
    name: チャットメッセージ
  - description: ファイルのアップロードとプレビューの操作です。
    name: ファイル操作
  - description: エンドユーザー情報に関連する操作です。
    name: エンドユーザー
  - description: ユーザーフィードバックの操作です。
    name: メッセージフィードバック
  - description: 会話管理に関連する操作です。
    name: 会話管理
  - description: テキスト読み上げと音声認識の操作です。
    name: 音声・テキスト変換
  - description: アプリケーション設定と情報を取得する操作です。
    name: アプリケーション設定
  - description: ダイレクト返信用のアノテーション管理に関連する操作です。
    name: アノテーション管理
  - description: 人間の入力を要する一時停止中のワークフローの再開操作です。
    name: 人間の入力
  - description: ワークフローの実行と管理のための操作です。
    name: ワークフロー実行
  - description: テキスト生成に関連する操作です。
    name: 完了メッセージ
  - description: ナレッジベースの作成、設定、取得を含むナレッジベース管理の操作です。
    name: ナレッジベース
  - description: ナレッジベース内のドキュメントの作成、更新、管理のための操作です。
    name: ドキュメント
  - description: ドキュメントチャンクと子チャンクの管理のための操作です。
    name: チャンク
  - description: ナレッジベースのメタデータフィールドとドキュメントメタデータ値の管理のための操作です。
    name: メタデータ
  - description: ナレッジベースタグとタグバインディングの管理のための操作です。
    name: タグ管理
  - description: 利用可能なモデルを取得するための操作です。
    name: モデル
  - description: データソースプラグインとパイプライン実行を含むナレッジパイプラインの管理と実行のための操作です。
    name: ナレッジパイプライン
paths:
  /datasets/{dataset_id}/documents/{document_id}/segments/{segment_id}/child_chunks:
    get:
      tags:
        - チャンク
      summary: 子チャンク一覧を取得
      description: 特定の親チャンク配下の子チャンクのページネーションリストを返します。
      operationId: getChildChunks
      parameters:
        - description: >-
            ナレッジベース ID
            です。[ナレッジベースリストを取得](/ja/api-reference/knowledge-bases/list-knowledge-bases)
            から取得します。
          in: path
          name: dataset_id
          required: true
          schema:
            format: uuid
            type: string
        - description: >-
            ドキュメント ID
            です。[ナレッジベースのドキュメントリストを取得](/ja/api-reference/documents/list-documents)
            から取得します。
          in: path
          name: document_id
          required: true
          schema:
            format: uuid
            type: string
        - description: >-
            親チャンク ID です。[チャンク一覧を取得](/ja/api-reference/chunks/list-chunks)
            から取得します。
          in: path
          name: segment_id
          required: true
          schema:
            format: uuid
            type: string
        - description: ページ番号。
          in: query
          name: page
          schema:
            default: 1
            minimum: 1
            type: integer
        - description: 1 ページあたりの項目数です。サーバーの上限は `100` です。
          in: query
          name: limit
          schema:
            default: 20
            minimum: 1
            type: integer
        - description: 検索キーワードです。
          in: query
          name: keyword
          schema:
            type: string
      responses:
        '200':
          content:
            application/json:
              examples:
                success:
                  summary: レスポンス例
                  value:
                    data:
                      - content: Dify is an open-source platform.
                        created_at: 1741267200
                        id: d7e8f9a0-1b2c-3d4e-5f6a-7b8c9d0e1f2a
                        position: 1
                        segment_id: f3d1c7be-9f3a-40d8-8eb8-3a1ef9c3f2c1
                        type: customized
                        updated_at: 1741267200
                        word_count: 6
                    limit: 20
                    page: 1
                    total: 1
                    total_pages: 1
              schema:
                properties:
                  data:
                    description: 子チャンクのリスト。
                    items:
                      $ref: '#/components/schemas/ChildChunk'
                    type: array
                  limit:
                    description: 1 ページあたりの件数です。
                    type: integer
                  page:
                    description: 現在のページ番号です。
                    type: integer
                  total:
                    description: 子チャンクの合計数です。
                    type: integer
                  total_pages:
                    description: 合計ページ数です。
                    type: integer
                type: object
          description: 子チャンクのリストです。
        '403':
          content:
            application/json:
              examples:
                forbidden:
                  summary: forbidden (api access)
                  value:
                    code: forbidden
                    message: Dataset api access is not enabled.
                    status: 403
          description: '`forbidden` : このナレッジベースでは API アクセスが有効になっていません。'
        '404':
          content:
            application/json:
              examples:
                not_found_1:
                  summary: not_found
                  value:
                    code: not_found
                    message: Dataset not found.
                    status: 404
                not_found_2:
                  summary: not_found
                  value:
                    code: not_found
                    message: Document not found.
                    status: 404
                not_found_3:
                  summary: not_found
                  value:
                    code: not_found
                    message: Segment not found.
                    status: 404
          description: |-
            - `not_found` : ナレッジベースが見つかりません。
            - `not_found` : ドキュメントが見つかりません。
            - `not_found` : チャンクが見つかりません。
components:
  schemas:
    ChildChunk:
      properties:
        content:
          description: 子チャンクのテキスト内容です。
          type: string
        created_at:
          description: 作成タイムスタンプ（Unix エポック、秒単位）です。
          type: number
        id:
          description: 子チャンクの一意識別子です。
          type: string
        position:
          description: 親チャンク内の子チャンクの位置です。
          type: integer
        segment_id:
          description: この子チャンクが属する親チャンクの ID です。
          type: string
        type:
          description: >-
            子チャンクの作成方法です。API から作成または更新された子チャンクは常に `customized` です。システム生成の子チャンクは
            `automatic` です。
          type: string
        updated_at:
          description: 最終更新タイムスタンプ（Unix エポック、秒単位）です。
          type: number
        word_count:
          description: 子チャンク内容の単語数です。
          type: integer
      type: object
  securitySchemes:
    ApiKeyAuth:
      bearerFormat: API_KEY
      description: >-
        すべてのリクエストは API キーで認証します：`Authorization: Bearer
        {API_KEY}`。アプリのエンドポイントにはアプリの API キーを、ナレッジのエンドポイントにはナレッジベースの API
        キーを使用します（[Dify API クイックスタート](/ja/api-reference/guides/get-started)）。


        キーはサーバーサイドで保管し、クライアントコードには決して埋め込まないでください。キーが欠落または無効なリクエストは HTTP
        `401`（`unauthorized`）で失敗します。
      scheme: bearer
      type: http

````