---
title: "pre-receive-hook"
url: "https://kiwi.arashsheyda.me/apis/git-hub-v3-rest-api-1/versions/4cb06d26-20a0-409c-8492-8406889b7eb4/schemas/pre-receive-hook"
---

> Full API specification: https://kiwi.arashsheyda.me/apis/git-hub-v3-rest-api-1/versions/4cb06d26-20a0-409c-8492-8406889b7eb4.md

# pre-receive-hook

## OpenAPI definition

```yaml
openapi: 3.0.3
info:
  title: GitHub v3 REST API
  version: 1.1.4
servers:
  - url: "{protocol}://{hostname}/api/v3"
    variables:
      hostname:
        description: Self-hosted Enterprise Server or Enterprise Cloud hostname
        default: HOSTNAME
      protocol:
        description: Self-hosted Enterprise Server or Enterprise Cloud protocol
        default: http
components:
  schemas:
    pre-receive-hook:
      type: object
      properties:
        id:
          type: integer
        name:
          type: string
        enforcement:
          type: string
        script:
          type: string
        script_repository:
          type: object
          properties:
            id:
              type: integer
            full_name:
              type: string
            url:
              type: string
            html_url:
              type: string
        environment:
          type: object
          properties:
            id:
              type: integer
            name:
              type: string
            image_url:
              type: string
            url:
              type: string
            html_url:
              type: string
            default_environment:
              type: boolean
            created_at:
              type: string
            hooks_count:
              type: integer
            download:
              type: object
              properties:
                url:
                  type: string
                state:
                  type: string
                downloaded_at:
                  nullable: true
                  type: string
                message:
                  nullable: true
                  type: string
        allow_downstream_configuration:
          type: boolean
```
