---
title: "List branches of a repository"
method: GET
path: "/api/v1/github/repositories/{owner}/{repo}/branches"
tags: ["GitHub"]
---

# List branches of a repository

`GET /api/v1/github/repositories/{owner}/{repo}/branches`

## Path parameters

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

## Query parameters

- `installationId` integer, required
- `after` string, nullable
- `first` integer, nullable

## Response `200`

- GitHubBranchesListResponse
  - `data` GitHubBranchResponse[], required — Deprecated: use `items` instead. Kept for backward compatibility.
    - `isDefault` boolean, required
    - `name` string, required
  - `items` GitHubBranchResponse[], required
    - `isDefault` boolean, required
    - `name` string, required
  - `pageInfo` PageInfo
    - `endCursor` string, nullable
    - `hasNextPage` boolean, required
    - `hasPreviousPage` boolean, required
    - `startCursor` string, nullable

## Changes

- **2026-08-27** `97e151460143` — 1 breaking, 1 warning, 5 info
  - added the new path request parameter `owner`
  - deleted the `query` request parameter `installationId`
  - added the new optional `query` request parameter `after`
  - added the new optional `query` request parameter `first`
  - …3 more
- **2026-08-17** `29d481391a25` — 1 breaking, 1 warning
  - added the new required `query` request parameter `installationId`
  - deleted the `query` request parameter `installationId`
- **2026-07-31** `a0c6b1d2ac96` — 1 info
  - endpoint added

[Change history](https://skmtc.dev/cube-js/apis/cube-cloud-rest-api/changes/api/v1/github/repositories/:owner/:repo/branches/get.md)

---

[API](https://skmtc.dev/cube-js/apis/cube-cloud-rest-api.md) · [All operations](https://skmtc.dev/cube-js/apis/cube-cloud-rest-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/cube-js/cube-cloud-rest-api/revisions/3adb3c5e66ca/schema)
