openapi: 3.1.0 info: title: DevCycle Bucketing Audiences Webhooks API description: Documents the DevCycle Bucketing API which provides an API interface to User Bucketing and for Server SDKs configured to use Cloud Bucketing. version: 1.3.0 servers: - url: https://bucketing-api.devcycle.com/ tags: - name: Webhooks paths: /v1/projects/{project}/webhooks: post: operationId: WebhooksController_create summary: Create Webhook description: Create a new Webhook parameters: - name: project required: true in: path description: A Project key or ID schema: type: string requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/CreateWebhookDto' responses: '201': description: '' content: application/json: schema: $ref: '#/components/schemas/Webhook' '400': description: '' '401': description: '' '403': description: '' '404': description: '' '409': description: '' tags: - Webhooks get: operationId: WebhooksController_findAll summary: List Webhooks description: List Webhooks parameters: - name: page required: false in: query schema: minimum: 1 default: 1 type: number - name: perPage required: false in: query schema: minimum: 1 maximum: 1000 default: 100 type: number - name: sortBy required: false in: query schema: default: createdAt enum: - createdAt - updatedAt - name - key - propertyKey type: string - name: sortOrder required: false in: query schema: default: desc enum: - asc - desc type: string - name: search required: false in: query schema: minLength: 3 type: string - name: createdBy required: false in: query schema: type: string - name: project required: true in: path description: A Project key or ID schema: type: string responses: '200': description: '' content: application/json: schema: type: array items: $ref: '#/components/schemas/Webhook' '400': description: '' '401': description: '' '403': description: '' '404': description: '' tags: - Webhooks /v1/projects/{project}/webhooks/{id}: patch: operationId: WebhooksController_update summary: Update Webhook description: Update a Webhook parameters: - name: id required: true in: path schema: type: string - name: project required: true in: path description: A Project key or ID schema: type: string requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/UpdateWebhookDto' responses: '200': description: '' content: application/json: schema: $ref: '#/components/schemas/Webhook' '400': description: '' '401': description: '' '403': description: '' '404': description: '' tags: - Webhooks get: operationId: WebhooksController_findOne summary: Get a Webhook description: Get a webhook by ID parameters: - name: id required: true in: path schema: type: string - name: project required: true in: path description: A Project key or ID schema: type: string responses: '200': description: '' content: application/json: schema: $ref: '#/components/schemas/Webhook' '401': description: '' '403': description: '' '404': description: '' tags: - Webhooks delete: operationId: WebhooksController_remove summary: Delete a Webhook description: Delete a webhook by ID parameters: - name: id required: true in: path schema: type: string - name: project required: true in: path description: A Project key or ID schema: type: string responses: '200': description: '' content: application/json: schema: $ref: '#/components/schemas/Webhook' '401': description: '' '403': description: '' '404': description: '' tags: - Webhooks components: schemas: CreateWebhookDto: type: object properties: name: type: string description: The name of the Webhook example: Slack maxLength: 100 minLength: 1 description: type: string description: The description of the Webhook example: Post in Slack when a feature is updated maxLength: 1000 outputFormat: type: object _feature: type: string _environments: type: array items: type: string events: description: The events that trigger the webhook example: - createdFeature - modifiedFeature type: array items: type: string url: type: string description: The URL to call once the type is triggered example: https://hooks.slack.com/services/... required: - name - events - url UpdateWebhookDto: type: object properties: name: type: string description: The name of the Webhook example: Slack maxLength: 100 minLength: 1 description: type: string description: The description of the Webhook example: Post in Slack when a feature is updated maxLength: 1000 _feature: type: string _environments: type: array items: type: string events: description: The events that trigger the webhook example: - createdFeature - modifiedFeature type: array items: type: string url: type: string description: The URL to call once the type is triggered example: https://hooks.slack.com/services/... outputFormat: type: object required: - _feature - _environments Webhook: type: object properties: name: type: string description: The name of the Webhook example: Slack maxLength: 100 minLength: 1 description: type: string description: The description of the Webhook example: Post in Slack when a feature is updated maxLength: 1000 _id: type: string description: A unique Webhook ID example: 61450f3daec96f5cf4a49946 _project: type: string description: The Project owning the Webhook example: 61450f3daec96f5cf4a49955 _feature: type: string description: Events in this webhook will only be triggered for this feature example: 61450f3daec96f5cf4a49956 _environments: description: Events in this webhook will only be triggered for these environments type: array items: type: string url: type: string description: The URL to call once the type is triggered example: https://hooks.slack.com/services/... events: description: The events that trigger the webhook example: - createdFeature - modifiedFeature type: array items: type: string source: description: Source where webhook was created from example: dashboard enum: - api - dashboard - importer - github.code_usages - github.pr_insights - gitlab.code_usages - gitlab.pr_insights - bitbucket.code_usages - bitbucket.pr_insights - terraform - cli - slack - mcp type: string createdBy: type: string description: Auth0 User who created the webhook. example: auth0|61450f3daec96f5cf4a49955 createdAt: format: date-time type: string description: The date the webhook was created, set by the API example: '2021-09-17T16:47:01.000Z' updatedAt: format: date-time type: string description: The date the webhook was last updated, set by the API example: '2021-09-17T16:47:01.000Z' outputFormat: type: object description: The type of format to send the payload changes in _slackIntegration: type: string description: The Slack Integration ID if the Webhook is created from a Slack command required: - name - _id - _project - _environments - url - events - createdAt - updatedAt securitySchemes: bearerAuth: type: apiKey in: header name: Authorization description: Enter your DevCycle SDK token