TwentyDEV icon

TwentyDEV

Consume the Twenty API

Actions252

Overview

This node operation creates a new message folder within a specified message channel. It is useful for organizing messages into folders programmatically, such as grouping conversations by topic, project, or priority. For example, you could automate the creation of folders to categorize incoming messages from different teams or clients.

Properties

Name Meaning
Depth Determines how much related nested information to include in the response:
- 0: Only the primary folder object.
- 1: The folder plus its directly related objects.
- 2: Folder, related objects, and their related objects.
Message Channel Id The identifier of the message channel where the new folder will be created.
Name The name of the new message folder to create.
Sync Cursor A sync cursor string used for synchronization purposes (likely to track changes or state).

Output

The output JSON contains the newly created message folder object. Depending on the Depth property, this object may include nested related objects up to two levels deep. This allows you to receive detailed information about the folder and its relationships immediately after creation.

No binary data output is indicated for this operation.

Dependencies

  • Requires an API key credential for authenticating with the Twenty API service.
  • The node uses the base URL provided by the credentials to send requests.
  • The operation sends a POST request with the folder details in the request body and includes the depth parameter as a query string.

Troubleshooting

  • Missing or invalid Message Channel Id: The API will likely return an error if the channel ID is not provided or incorrect. Ensure the channel exists and the ID is valid.
  • Invalid folder name: If the name is empty or contains invalid characters, the API might reject the request.
  • Authentication errors: Verify that the API key credential is correctly configured and has sufficient permissions.
  • Sync Cursor issues: If using the sync cursor, ensure it is valid; otherwise, synchronization may fail or behave unexpectedly.
  • Depth parameter misuse: Using unsupported depth values may cause unexpected responses or errors.

Links and References

Discussion