---
title: "Get Scan History"
method: POST
path: "/api/analysis/scan-history"
tags: ["Analysis"]
---

# Get Scan History

`POST /api/analysis/scan-history`

Retrieves the scan history for a repository, returning the last analysis results for each commit that has been scanned

## Request body

- ScanHistoryRequest
  - `repo` string, required — Repository identifier (format varies by platform)
  - `platform` 'github' | 'azuredevops' | 'gitlab' | 'bitbucket', required — Version control platform
  - `org` string, required — Organization or workspace name
  - `github_base_url` string — GitHub base URL (for self-hosted instances)
  - `gitlab_base_url` string — GitLab base URL (for self-hosted instances)
  - `azure_devops_base_url` string — Azure DevOps base URL
  - `bitbucket_base_url` string — Bitbucket base URL (for self-hosted instances)

## Response `200`

Scan history retrieved successfully

- ScanHistoryResponse
  - `repo` string — Repository identifier
  - `last_analysis_results` object[] — List of last analysis results for each scanned commit

## Other responses

- `400` — Missing required parameters
- `401` — Invalid or missing access token
- `500` — Internal server error

---

[API](https://skmtc.dev/codeant/apis/codeant-ai-api.md) · [All operations](https://skmtc.dev/codeant/apis/codeant-ai-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/codeant/codeant-ai-api/revisions/d1eb7c083a39/schema)
