---
title: "get status of prepare gc commits operation"
method: GET
path: "/repositories/{repository}/gc/prepare_commits/status"
tags: ["internal"]
---

# get status of prepare gc commits operation

`GET /repositories/{repository}/gc/prepare_commits/status`

## Request

- Base URL: `/api/v1` (relative, and the document was published on a file host, not at the API’s origin)
- URL: `/api/v1/repositories/{repository}/gc/prepare_commits/status`
- Auth: one of:
  - HTTP bearer
  - HTTP basic
  - API key in cookie `internal_auth_session`

## Query parameters

- `id` string, required

## Response `200`

prepare GC commits task status

- PrepareGarbageCollectionCommitsStatus
  - `task_id` string, required: the id of the task preparing the GC commits
  - `completed` boolean, required: true if the task has completed (either successfully or with an error)
  - `update_time` string, date-time, required: last time the task status was updated
  - `result` GarbageCollectionPrepareResponse
    - `run_id` string, required: a unique identifier generated for this GC job
    - `gc_commits_location` string, required: location of the resulting commits csv table (partitioned by run_id)
    - `gc_addresses_location` string, required: location to use for expired addresses parquet table (partitioned by run_id)
    - `gc_commits_presigned_url` string: a presigned url to download the commits csv
  - `error` Error
    - `message` string, required: short message explaining the error

## Other responses

- `400`: Bad Request
- `401`: Unauthorized
- `403`: Forbidden
- `404`: Resource Not Found
- `429`: too many requests
- `default`: Internal Server Error

## Changes

- **2025-11-24** `add5a8870f32`: 1 info
  - added the non-success response with the status `400`
- **2025-11-06** `b0f68552aba1`: 1 info
  - endpoint added
- **2024-09-17** `3b10653a8013`: 1 breaking
  - api path removed without deprecation

[Operation history](https://skmtc.dev/treeverse/apis/lakefs-api/changes/repositories/:repository/gc/prepare_commits/status/get.md)

---

[API](https://skmtc.dev/treeverse/apis/lakefs-api.md) - [All operations](https://skmtc.dev/treeverse/apis/lakefs-api/llms.txt) - [OpenAPI document](https://skmtc.dev/treeverse/apis/lakefs-api/revisions/10a3acbbb1fd?raw)
