---
title: "Returns packaged hotspot recommendations for a repo-scoped file path."
method: GET
path: "/api/projects/{project-id}/quality/hotspots/recommendations"
tags: ["quality"]
---

# Returns packaged hotspot recommendations for a repo-scoped file path.

`GET /api/projects/{project-id}/quality/hotspots/recommendations`

## Request

- Base URL: `https://codescene.io` (the document declares no server; this is the origin it was published from)
- URL: `https://codescene.io/api/projects/{project-id}/quality/hotspots/recommendations`
- Auth: none declared

## Path parameters

- `project-id` integer, required

## Query parameters

- `path` string, required

## Response `200`

- union
  - object
    - `path` string, required: Repo-scoped file path used to identify the hotspot.
    - `hotspotName` string, required: Qualified hotspot name returned by analysis.
    - `recommendations` object[], required: Ordered hotspot recommendations for the requested file.
      - `rank` integer, required: Rank of the recommendation in descending priority order.
      - `scope` 'function' | 'file', required: Whether the recommendation applies to a function or the file.
      - `target` string, required: Recommended function name or file path.
      - `recommendationType` string, required: Deterministic recommendation type selected by analysis.
      - `text` string, required: Predefined human-readable recommendation text.
      - `evidence` object, required: Supporting evidence for why this recommendation was selected.
        - `revisions` integer: Number of revisions for the recommended function in the analysis period.
        - `loc` integer: Lines of code for the recommended function.
        - `cyclomaticComplexity` integer: Cyclomatic complexity for the recommended function.
        - `defects` integer: Historical defects associated with the recommended function when available.
        - `codeHealthIssues` string[], required: Code Health issues supporting the recommendation.
  - object
    - `status` 'healthy' | 'not_uplift_target' | 'feature_unavailable', required: Domain status reported when no packaged recommendations are returned.
    - `message` string, required: Human-readable explanation for the returned status.

## Other responses

- `400`
- `401`
- `403`
- `404`

---

[API](https://skmtc.dev/codescene/apis/codescene-api.md) · [All operations](https://skmtc.dev/codescene/apis/codescene-api/llms.txt) · [OpenAPI document](https://skmtc.dev/codescene/apis/codescene-api/revisions/e443e0b6bc89?raw)
