# webhook_https_required (/errors/webhook_https_required)

| HTTP status | Type | Code |
| --- | --- | --- |
| 400 | `invalid_request_error` | `webhook_https_required` |

## What it means [#what-it-means]

Webhook payloads carry customer data, so endpoints must use TLS. Change the URL to start with `https://`.

## How to handle it [#how-to-handle-it]

Fix the request before sending it again; retrying the same request returns the same error. `error.param` names the offending field when there is one.

## Example response [#example-response]

```json
{
  "detail": "The webhook URL must use https.",
  "error": {
    "type": "invalid_request_error",
    "code": "webhook_https_required",
    "message": "The webhook URL must use https.",
    "param": null,
    "docUrl": "https://docs.callmitra.ai/errors/webhook_https_required",
    "requestId": "req_3f9c2a7d1b8e4c6a9f0e2d4b6a8c0e1f"
  }
}
```

Branch on `error.code`; it never changes once published. The `message` text can change. See [Errors](/errors) for the envelope.

## Returned by [#returned-by]

- `POST /api/v1/webhook-endpoints/` — Create a webhook endpoint
- `PATCH /api/v1/webhook-endpoints/{endpoint_id}` — Update a webhook endpoint