github.com/danp/terraform@v0.9.5-0.20170426144147-39d740081351/website/source/docs/providers/github/r/repository_webhook.html.markdown (about) 1 --- 2 layout: "github" 3 page_title: "GitHub: github_repository_webhook" 4 sidebar_current: "docs-github-resource-repository-webhook" 5 description: |- 6 Creates and manages repository webhooks within Github organizations 7 --- 8 9 # github_repository_webhook 10 11 This resource allows you to create and manage webhooks for repositories within your 12 Github organization. 13 14 This resource cannot currently be used to manage webhooks for *personal* repositories, 15 outside of organizations. 16 17 ## Example Usage 18 19 ```hcl 20 resource "github_repository" "repo" { 21 name = "foo" 22 description = "Terraform acceptance tests" 23 homepage_url = "http://example.com/" 24 25 private = false 26 } 27 28 resource "github_repository_webhook" "foo" { 29 repository = "${github_repository.repo.name}" 30 31 name = "web" 32 33 configuration { 34 url = "https://google.de/" 35 content_type = "form" 36 insecure_ssl = false 37 } 38 39 active = false 40 41 events = ["issues"] 42 } 43 ``` 44 45 ## Argument Reference 46 47 The following arguments are supported: 48 49 * `name` - (Required) The type of the webhook. See a list of [available hooks](https://api.github.com/hooks). 50 51 * `repository` - (Required) The repository of the webhook. 52 53 * `events` - (Required) A list of events which should trigger the webhook. Defaults to `["push"]`. See a list of [available events](https://developer.github.com/v3/activity/events/types/) 54 55 * `config` - (Required) key/value pair of configuration for this webhook. Available keys are `url`, `content_type`, `secret` and `insecure_ssl`. 56 57 * `active` - (Optional) Indicate of the webhook should receive events. Defaults to `true`. 58 59 ## Attributes Reference 60 61 The following additional attributes are exported: 62 63 * `url` - URL of the webhook