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

# スキャンの依存関係を取得

> 指定したスキャンのソフトウェア依存関係（SBOM）を取得します。



## OpenAPI

````yaml /ja/api-reference/openapi.json get /scan/{scan_id}/dependencies
openapi: 3.0.0
info:
  title: Corgea API
  version: 1.0.0
  description: Corgeaのスキャン機能および脆弱性管理機能を操作するためのAPI
servers:
  - url: https://www.corgea.app/api/v1
    description: 本番サーバー
security:
  - CorgeaToken: []
  - BearerAuth: []
paths:
  /scan/{scan_id}/dependencies:
    get:
      tags:
        - 依存関係
      summary: スキャンの依存関係を取得
      description: 指定したスキャンのソフトウェア依存関係（SBOM）を取得します。
      operationId: getScanDependencies
      parameters:
        - name: scan_id
          in: path
          required: true
          schema:
            type: string
            format: uuid
          description: スキャンID
        - name: page
          in: query
          required: false
          schema:
            type: integer
            default: 1
          description: ページネーションのページ番号
        - name: page_size
          in: query
          required: false
          schema:
            type: integer
            default: 20
            maximum: 50
          description: 1ページあたりの結果件数
        - name: name
          in: query
          required: false
          schema:
            type: string
          description: 依存関係名で絞り込みます（部分一致）
          example: django
        - name: version
          in: query
          required: false
          schema:
            type: string
          description: 依存関係のバージョンで絞り込みます
          example: 4.2.0
        - name: type
          in: query
          required: false
          schema:
            type: string
          description: 依存関係のエコシステムまたはパッケージタイプで絞り込みます
          example: pypi
        - name: path
          in: query
          required: false
          schema:
            type: string
          description: ファイルパスで絞り込みます（部分一致）
          example: requirements.txt
        - name: purl
          in: query
          required: false
          schema:
            type: string
          description: パッケージURLで絞り込みます（部分一致）
          example: pkg:pypi/django
        - name: license
          in: query
          required: false
          schema:
            type: string
          description: ライセンスで絞り込みます
          example: MIT
        - name: dep_type
          in: query
          required: false
          schema:
            type: string
            enum:
              - direct
              - transitive
              - all
            default: all
          description: 依存関係の種類で絞り込みます
          example: direct
        - name: search
          in: query
          required: false
          schema:
            type: string
          description: 依存関係名、バージョン、パッケージURLを横断して検索します
          example: lodash
        - name: sort_by
          in: query
          required: false
          schema:
            type: string
            enum:
              - name
              - '-name'
              - version
              - '-version'
              - type
              - '-type'
              - created_at
              - '-created_at'
          description: フィールドで結果を並べ替えます（降順の場合は先頭に「-」を付けます）
          example: name
      responses:
        '200':
          description: スキャンの依存関係を正常に取得しました
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    example: ok
                  page:
                    type: integer
                  total_pages:
                    type: integer
                  total_dependencies:
                    type: integer
                  dependencies:
                    type: array
                    items:
                      $ref: '#/components/schemas/Dependency'
        '400':
          description: 依存関係タイプのフィルターが無効です
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    example: error
                  message:
                    type: string
                    example: 'Invalid dep_type. Must be one of: direct, transitive, all.'
        '403':
          description: 権限がありません
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    example: Permission denied
        '404':
          description: スキャンが見つかりません
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    example: error
                  message:
                    type: string
                    example: Scan not found
components:
  schemas:
    Dependency:
      type: object
      properties:
        id:
          type: string
          format: uuid
        name:
          type: string
        version:
          type: string
        type:
          type: string
        purl:
          type: string
        path:
          type: string
        licenses:
          type: array
          items:
            type: string
        properties:
          type: array
          items: {}
        is_direct:
          type: boolean
        parent_id:
          type: string
          nullable: true
        source_id:
          type: string
          nullable: true
        created_at:
          type: string
          format: date-time
        scan:
          type: object
          properties:
            id:
              type: string
              format: uuid
              nullable: true
            branch:
              type: string
              nullable: true
            project:
              type: string
              nullable: true
  securitySchemes:
    CorgeaToken:
      type: apiKey
      in: header
      name: CORGEA-TOKEN
      description: 認証用のAPIキー
    BearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: Authorizationヘッダーで使用するOAuth2アクセストークン（JWT）

````