TwentyDEV icon

TwentyDEV

Consume the Twenty API

Actions252

Overview

This node operation allows users to create multiple webhooks at once via the Twenty API. It is useful when you need to programmatically register several webhook endpoints in bulk, for example, to automate event handling or integrate with external services that send data via webhooks. Practical scenarios include setting up multiple webhook listeners for different events or environments without manually creating each one.

Properties

Name Meaning
Depth Determines how much related nested information is included in the response:
- 0: Only the primary webhook objects.
- 1: Primary webhooks plus their directly related objects.
- 2: Includes related objects of those related objects as well.
Body JSON object representing the webhook(s) to create. This should contain the details of the webhook(s) according to the API specification.

Output

The output json field contains the response from the API after creating the webhooks. Depending on the depth parameter, it includes the created webhook objects and optionally their related nested objects. The structure corresponds to the API's webhook resource representation.

No binary data output is indicated by the source code.

Dependencies

  • Requires an API key credential for authenticating with the Twenty API.
  • The node uses the base URL provided by the user's credentials configuration.
  • The request content type is JSON, so the node expects valid JSON input for the webhook body.

Troubleshooting

  • Invalid JSON in Body: If the "Body" property contains malformed JSON, the node will fail to parse it. Ensure the JSON is correctly formatted.
  • Authentication Errors: Missing or invalid API credentials will cause authentication failures. Verify that the API key or token is correctly configured.
  • API Response Errors: If the API rejects the webhook creation (e.g., due to invalid fields), the error message from the API will be returned. Check the webhook data against the API documentation.
  • Depth Parameter Misuse: Using a depth value not supported by the API may result in unexpected responses or errors. Use only 0, 1, or 2 as specified.

Links and References

Discussion