> ## 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.

# コード品質の問題を一覧表示

> コード品質の検出結果をセキュリティ問題とは別に取得します。classificationの値にはCWEではなく、Maintainabilityなどのコード品質ラベルが使用されます。



## OpenAPI

````yaml /ja/api-reference/openapi.json get /issues/code-quality
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:
  /issues/code-quality:
    get:
      tags:
        - 問題
      summary: コード品質の問題を一覧表示
      description: >-
        コード品質の検出結果をセキュリティ問題とは別に取得します。classificationの値にはCWEではなく、Maintainabilityなどのコード品質ラベルが使用されます。
      operationId: listCodeQualityIssues
      parameters:
        - name: project
          in: query
          schema:
            type: string
          description: プロジェクト名で問題を絞り込みます
        - name: repo
          in: query
          schema:
            type: string
          description: リポジトリURLで問題を絞り込みます
        - name: branch
          in: query
          schema:
            type: string
          description: ブランチ名で問題を絞り込みます
        - name: classification
          in: query
          schema:
            type: string
          description: コード品質の分類ラベルで絞り込みます（部分一致）
          example: Maintainability
        - name: page
          in: query
          schema:
            type: integer
            default: 1
        - name: page_size
          in: query
          schema:
            type: integer
            default: 20
            maximum: 50
      responses:
        '200':
          description: コード品質の問題を正常に取得しました
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    example: ok
                  page:
                    type: integer
                  total_pages:
                    type: integer
                  total_issues:
                    type: integer
                  issues:
                    type: array
                    items:
                      $ref: '#/components/schemas/Issue'
components:
  schemas:
    Issue:
      type: object
      properties:
        id:
          type: string
          format: uuid
        classification:
          type: object
          properties:
            id:
              type: string
              example: CWE-123
            name:
              type: string
              example: Vulnerability Name
            description:
              type: string
              nullable: true
        urgency:
          type: string
          enum:
            - critical
            - high
            - medium
            - low
        created_at:
          type: string
          format: date-time
        status:
          type: string
          enum:
            - open
            - in_progress
            - fixed
            - accepted_risk
            - false_positive
        sla_status:
          type: string
          enum:
            - on_track
            - due
            - overdue
        location:
          $ref: '#/components/schemas/IssueLocation'
        auto_triage:
          $ref: '#/components/schemas/AutoTriage'
        auto_fix_suggestion:
          $ref: '#/components/schemas/AutoFixSuggestion'
        assigned_to:
          $ref: '#/components/schemas/AssignedTo'
        scanner_metadata:
          type: object
          description: スキャナーが提供し、問題に関連付けられたメタデータ。
          additionalProperties:
            type: string
        reachability:
          $ref: '#/components/schemas/IssueReachabilitySummary'
    IssueLocation:
      type: object
      properties:
        file:
          type: object
          properties:
            name:
              type: string
            language:
              type: string
            path:
              type: string
        project:
          type: object
          properties:
            name:
              type: string
            branch:
              type: string
            git_sha:
              type: string
        line_number:
          type: integer
    AutoTriage:
      type: object
      properties:
        false_positive_detection:
          type: object
          properties:
            status:
              type: string
              enum:
                - valid
                - false_positive
                - pending
            reasoning:
              type: string
    AutoFixSuggestion:
      type: object
      properties:
        id:
          type: string
          format: uuid
        status:
          type: string
          enum:
            - fix_available
            - no_fix
            - false_positive
            - on_hold
            - unsupported
            - plan
          description: >-
            現在の修正の利用可否。問題の取得リクエストでは、生成可能で未生成の修正がデフォルトで生成されます。生成が無効な場合、または修正が生成されない場合、ステータスはno_fixになります。
        patch:
          type: object
          properties:
            diff:
              type: string
              description: unified diff形式のパッチ
            explanation:
              type: string
              description: 修正によって脆弱性がどのように解消されるかの説明
    AssignedTo:
      type: object
      nullable: true
      description: 問題の担当ユーザー。未割り当ての場合はnullです。
      properties:
        id:
          type: string
          description: 担当ユーザーのID。
        email:
          type: string
          format: email
          description: 担当ユーザーのメールアドレス。
        name:
          type: string
          nullable: true
          description: 担当ユーザーの表示名。利用できない場合はnullです。
    IssueReachabilitySummary:
      type: object
      description: include_reachabilityがtrueの場合に返されるエンドポイント到達可能性の概要。
      properties:
        is_reachable:
          type: boolean
        endpoint_count:
          type: integer
  securitySchemes:
    CorgeaToken:
      type: apiKey
      in: header
      name: CORGEA-TOKEN
      description: 認証用のAPIキー
    BearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: Authorizationヘッダーで使用するOAuth2アクセストークン（JWT）

````