---
title: "List pre-receive hooks for a repository"
method: GET
path: "/repos/{owner}/{repo}/pre-receive-hooks"
tags: ["enterprise-admin"]
---

# List pre-receive hooks for a repository

`GET /repos/{owner}/{repo}/pre-receive-hooks`

List all pre-receive hooks that are enabled or testing for this repository as well as any disabled hooks that are allowed to be enabled at the repository level. Pre-receive hooks that are disabled at a higher level and are not configurable will not be listed.

## Path parameters

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

## Query parameters

- `per_page` integer
- `page` integer
- `direction` 'asc' | 'desc'
- `sort` 'created' | 'updated' | 'name'

## Response `200`

Response

- RepositoryPreReceiveHook[]
  - `id` integer
  - `name` string
  - `enforcement` string
  - `configuration_url` string

---

[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/versions/50ae54440071/schema)
