---
title: "How to use the deploy webhook URL?"
url: "https://ploi.io/documentation/deployment/how-to-use-the-deploy-webhook-url"
published: "2024-08-07"
last_updated: "2026-06-15"
---

# How to use the deploy webhook URL?

The deploy webhook URL is a great way to automate your deployments. Either via GitHub Actions or another CI system, with the deploy webhook URL you can deploy whenever you want.

You can find the deploy webhook URL in your site, in the **Repository** tab, look for the **Deploy webhook URL** card. In there you can easily copy the deploy webhook URL or refresh the token, in case you think it got exposed or needs swapping.

The deploy URL requires a `POST` or `OPTIONS` method and the URL structure looks like this: `https://ploi.io/webhooks/servers/1/sites/1/deploy?token=bVKlWN.....&direct=true`

Additionally, you may pass in variables as query parameters or a JSON body that'll be available inside your deploy script.

### Example URL via query parameters

`https://ploi.io/webhooks/servers/1/sites/1/deploy?token=xOUr...&direct=true&variables[tag]=v1.0.0&variables[branch]=staging`

### Example URL with JSON body

`https://ploi.io/webhooks/servers/1/sites/1/deploy?token=xOUr...&direct=true`

JSON body:

```
{
    "variables": {
        "tag": "v1.0.0",
        "branch": "staging"
    }
}
```

In both examples, the variables `$TAG` and `$BRANCH` will be available inside your deploy script:

```
cd /home/ploi/ploi.io

echo $TAG
echo $BRANCH
```

Output:

```
v1.0.0
staging
```