---
title: "Set or update the board's webhook"
method: POST
path: "/api/board/{boardId}/webhook"
tags: ["Board"]
---

# Set or update the board's webhook

`POST /api/board/{boardId}/webhook`

## Request

- Base URL: `https://core-api.getaptly.com`
- URL: `https://core-api.getaptly.com/api/board/{boardId}/webhook`
- Auth: one of:
  - API key in header `x-token`
  - API key in header `Authorization`
- TypeScript: <https://skmtc.dev/getaptly/apis/aptly-api/docs/api/board/:boardId/webhook/post.ts> (a function with typed inputs; its response is checked against the schema)

Sets the board's webhook URL. Calling this again re-points an existing webhook (an
update) rather than creating a second one — a board has at most one webhook.

A new `webhookSigningKey` is generated every time this is called, including on
update, so re-pointing a webhook also rotates its signing key.

## Path parameters

- `boardId` string, required

## Request body

- object
  - `webhookUrl` string, required: Must be a valid http or https URL.

## Response `201`

Webhook set.

- object
  - `data` object
    - `webhookUrl` string
    - `webhookSigningKey` string: Shared secret used to sign the webhook payload.

## Other responses

- `400`: Missing or invalid `webhookUrl`.
- `401`: Invalid or missing API key.
- `403`: API access is disabled for this board, or the key lacks insert/update permission.
- `404`: Board not found.

---

[API](https://skmtc.dev/getaptly/apis/aptly-api.md) - [All operations](https://skmtc.dev/getaptly/apis/aptly-api/llms.txt) - [OpenAPI document](https://skmtc.dev/getaptly/apis/aptly-api/revisions/75c367e0b8e5?raw)
