-
-
Notifications
You must be signed in to change notification settings - Fork 0
Setup Webhook
Kim Oliver Drechsel edited this page Aug 11, 2024
·
3 revisions
This page shows how to set up a webhook for your deployments.
A webhook is a http request that is sent to a URL when a specific event occurs.
- Go to your repository settings.
- Click on
Webhooks
. - Click on the
Add webhook
button. - Fill in the following fields:
-
Payload URL: The URL to the app endpoint, e.g.
https://example.com/v1/webhook
. -
Content type: Set this to
application/json
. -
Secret: The
WEBHOOK_SECRET
you have set in your app configuration (See App Settings). - SSL verification: Enable this if you have a valid SSL certificate for the app endpoint.
-
Which events would you like to trigger this webhook?: Set this to
Just the push event
orLet me select individual events
and thenPushes
and/orBranch or tag creation
. - Active: Enable this to activate the webhook.
-
Payload URL: The URL to the app endpoint, e.g.
- Go to your repository settings.
- Click on
Webhooks
. - Click on the
Add webhook
button and selectGitea
in the dropdown. - Fill in the following fields:
-
Target URL: The URL to the app endpoint, e.g.
https://example.com/v1/webhook
. -
HTTP Method: Set to
POST
. -
POST Content Type: Set to
application/json
. -
Secret: The
WEBHOOK_SECRET
you have set in your app configuration (See App Settings). -
Trigger On: Set this to
Push Events
orCustom Events...
and thenCreate
and/orPush
. -
Branch filter: Set this to the branch you want to trigger the webhook or
*
for all branches. - Active: Enable this to activate the webhook.
-
Target URL: The URL to the app endpoint, e.g.
- Go to your repository settings.
- Click on
Webhooks
. - Click on the
Add new webhook
button. - Fill in the following fields:
-
URL: The URL to the app endpoint, e.g.
https://example.com/v1/webhook
. -
Secret Token: The
WEBHOOK_SECRET
you have set in your app configuration (See App Settings). -
Trigger: Set this to
Push events
and/orTag push events
. - SSL verification: Enable this if you have a valid SSL certificate for the app endpoint.
-
URL: The URL to the app endpoint, e.g.
- Click on the
Test
button and thenPush events
to test the webhook.