---
updatedAt: 2026-04-21T05:36:37.000Z
agentTools:
  projectIndex: https://developer.officernd.com/llms.txt
---

# Add a new webhook

Add a new webhook 

 Required scopes: `flex.settings.webhooks.create`

# OpenAPI definition

```json
{
  "openapi": "3.0.0",
  "paths": {
    "/api/v2/organizations/{orgSlug}/webhooks": {
      "post": {
        "description": "Add a new webhook \n\n Required scopes: `flex.settings.webhooks.create`",
        "operationId": "WebhooksController_addItem_api/v2",
        "parameters": [
          {
            "name": "orgSlug",
            "required": true,
            "in": "path",
            "description": "organization slug",
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/AddWebhookDto"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WebhookResultDto"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "flex.settings.webhooks.create"
            ]
          }
        ],
        "summary": "Add a new webhook",
        "tags": [
          "Webhooks"
        ]
      }
    }
  },
  "info": {
    "title": "Settings API",
    "description": "",
    "version": "2.0",
    "contact": {}
  },
  "servers": [
    {
      "url": "https://app.officernd.com"
    }
  ],
  "components": {
    "securitySchemes": {
      "oauth2": {
        "type": "oauth2",
        "flows": {
          "clientCredentials": {
            "tokenUrl": "https://identity.officernd.com/auth/token",
            "scopes": {}
          },
          "authorizationCode": {
            "authorizationUrl": "https://identity.officernd.com/auth/authorize",
            "tokenUrl": "https://identity.officernd.com/auth/token",
            "scopes": {}
          }
        }
      }
    },
    "schemas": {
      "WebhookResultDto": {
        "type": "object",
        "properties": {
          "_id": {
            "type": "string",
            "description": "The _id of the webhook.",
            "example": "6acde3f82d2ed42e8be32b3a"
          },
          "url": {
            "type": "string",
            "description": "The URL of the endpoint of your server where POST requests will be made.",
            "example": "https://webhook.site/1b1b1b1b-1b1b-1b1b-1b1b-1b1b1b1b1b1b"
          },
          "description": {
            "type": "string",
            "description": "A description of the webhook.",
            "example": "A webhook for testing purposes."
          },
          "eventTypes": {
            "description": "An array containg the type of events associated with the webhook.",
            "example": [
              "membership.created",
              "membership.updated"
            ],
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "secret": {
            "type": "string",
            "description": "The secret key used to sign the webhook payload.",
            "example": "1b1b1b1b-1b1b-1b1b-1b1b-1b1b1b1b1b1b"
          },
          "isEnabled": {
            "type": "boolean",
            "description": "Determines whether the webhook is enabled. If left empty the webhook will be turned on by default.",
            "example": true
          }
        }
      },
      "AddWebhookDto": {
        "type": "object",
        "properties": {
          "eventTypes": {
            "description": "An array containg the type of events associated with the webhook.",
            "example": [
              "membership.created",
              "membership.updated"
            ],
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "url": {
            "type": "string",
            "description": "The URL of the endpoint of your server where POST requests will be made.",
            "example": "https://webhook.site/1b1b1b1b-1b1b-1b1b-1b1b-1b1b1b1b1b1b"
          },
          "description": {
            "type": "string",
            "description": "A description of the webhook.",
            "example": "A webhook for testing purposes."
          },
          "isEnabled": {
            "type": "boolean",
            "description": "Determines whether the webhook is enabled. If left empty the webhook will be turned on by default.",
            "example": true
          }
        },
        "required": [
          "eventTypes",
          "url"
        ]
      }
    }
  }
}
```