---
title: "List extinctions"
method: GET
path: "/api/v2/code-refs/extinctions"
tags: ["Code references"]
---

# List extinctions

`GET /api/v2/code-refs/extinctions`

Get a list of all extinctions. LaunchDarkly creates an extinction event after you remove all code references to a flag. To learn more, read [About extinction events](https://launchdarkly.com/docs/home/observability/code-references#about-extinction-events).

## Query parameters

- `repoName` string, string — Filter results to a specific repository
- `branchName` string, string — Filter results to a specific branch. By default, only the default branch will be queried for extinctions.
- `projKey` string, string — Filter results to a specific project
- `flagKey` string, string — Filter results to a specific flag key
- `from` integer — Filter results to a specific timeframe based on commit time, expressed as a Unix epoch time in milliseconds. Must be used with `to`.
- `to` integer — Filter results to a specific timeframe based on commit time, expressed as a Unix epoch time in milliseconds. Must be used with `from`.

## Response `200`

Extinction collection response

- ExtinctionCollectionRep
  - `_links` object, required — The location and content type of related resources
  - `items` object, required — An array of extinction events

## Other responses

- `401` — Invalid access token
- `403` — Forbidden
- `429` — Rate limited

---

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