---
search:
  tags:
    - Webhooks
    - POST
seo:
  description: >-
    Create a webhook endpoint. Reference for the POST /api/v1/webhooks endpoint
    in the torqee Connect API.
sidebar:
  label: Create a webhook endpoint
  badge: POST
title: Create a webhook endpoint
type: openapi-operation
---
`POST /api/v1/webhooks`

**Request body** (`application/json`, required)

- `name` (string, required)
- `url` (string<uri>, required)
- `filters` (object[], required)
- `enabled` (boolean)

Request body example:

```json
{
  "name": "string",
  "url": "http://example.com",
  "filters": [
    {
      "type": "session.created",
      "sessionId": "string"
    }
  ],
  "enabled": true
}
```

**Responses**

- `201` — Created endpoint
- `400` — Invalid endpoint or filters
- `401` — Missing or invalid credentials
- `403` — Membership revoked or insufficient scope
- `404` — Tenant database could not be resolved for the workspace
- `500` — Unexpected server error

Response example, 201:

```json
{
  "id": "string",
  "name": "string",
  "url": "http://example.com",
  "filters": [
    {
      "type": "session.created",
      "sessionId": "string"
    }
  ],
  "enabled": true,
  "createdAt": "2019-08-24T14:15:22Z",
  "updatedAt": "2019-08-24T14:15:22Z"
}
```
