# WebhookUrl

`function` in `gateway` · v0.1.0-next.3

<https://docs.seedcord.org/packages/gateway/0.1.0-next.3/functions/webhook-url>

Declares the environment variable a [`WebhookLog`](/packages/gateway/0.1.0-next.3/classes/webhook-log) reporter reads its webhook url from.

An unset variable disables the reporter with a boot warning. A set but malformed value throws at boot.

```ts
WebhookUrl(
    envKey: string
): <HandlerCtor extends Constructor<WebhookLog<SubscriptionKey>>>(
    constructor: HandlerCtor
) => void
```

Declares the environment variable a [`WebhookLog`](/packages/gateway/0.1.0-next.3/classes/webhook-log) reporter reads its webhook url from.

An unset variable disables the reporter with a boot warning. A set but malformed value throws at boot.

Parameters.

- `envKey` `string` — The environment variable name holding the webhook url

Returns `<HandlerCtor extends Constructor<WebhookLog<SubscriptionKey>>>(constructor: HandlerCtor) => void`.
