---
title: "Get a diff of the dependencies between commits"
method: GET
path: "/repos/{owner}/{repo}/dependency-graph/compare/{basehead}"
tags: ["dependency-graph"]
---

# Get a diff of the dependencies between commits

`GET /repos/{owner}/{repo}/dependency-graph/compare/{basehead}`

Gets the diff of the dependency changes between two commits of a repository, based on the changes to the dependency manifests made in those commits.

## Path parameters

- `owner` string, required
- `repo` string, required
- `basehead` string, required

## Query parameters

- `name` string

## Response `200`

Response

- object[] — A diff of the dependencies between two commits.
  - `change_type` 'added' | 'removed', required
  - `manifest` string, required
  - `ecosystem` string, required
  - `name` string, required
  - `version` string, required
  - `package_url` string, nullable, required
  - `license` string, nullable, required
  - `source_repository_url` string, nullable, required
  - `vulnerabilities` object[], required
    - `severity` string, required
    - `advisory_ghsa_id` string, required
    - `advisory_summary` string, required
    - `advisory_url` string, required

## Other responses

- `403` — Response if GitHub Advanced Security is not enabled for this repository
- `404` — Resource not found

---

[API](https://skmtc.net/github/apis/github-v3-rest-api-5.md) · [All operations](https://skmtc.net/github/apis/github-v3-rest-api-5/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/github/github-v3-rest-api-5/revisions/50ae54440071/schema)
