Surense icon

Surense

Interact with Surense API

Workflow → Create a Workflow

AI-generated

Overview

This node integrates with the Surense API to manage various resources, including workflows. Specifically, for the Workflow - Create operation, it allows users to create a new workflow in the Surense system by specifying key details such as owner, assigned user, workflow type, and customer ID. Additional optional parameters like templates, related leads, and due dates can also be set.

This node is beneficial in automation scenarios where workflows need to be programmatically created based on dynamic data or triggers within n8n. For example, when a new customer is onboarded, an automated workflow can be created and assigned to specific users with deadlines and templates predefined.

Properties

Name Meaning
Owner Name or ID Select or specify the owner of the workflow. Can be chosen from a list of users or provided via an expression.
Assigned User Name or ID Select or specify the user assigned to handle the workflow. Can be chosen from a list of users or provided via an expression.
Type Name or ID Select or specify the workflow type. Options are loaded dynamically from available workflow types.
Customer ID The unique identifier (UUID format) of the customer associated with the workflow.
Template Name or ID (Optional) Select or specify a workflow template to base the new workflow on. Loaded dynamically from available templates.
Lead ID (Optional) Related lead's unique identifier (UUID format) to associate with the workflow.
Due Date (Optional) The date by which the workflow should be handled. Format: YYYY-MM-DD.
Due Time (Optional) The time by which the workflow should be handled. Format: HH:MM (24-hour).

Output

The node outputs an array of JSON objects representing the result of the workflow creation operation for each input item. Each output item contains the response data from the Surense API about the newly created workflow, including its identifiers and metadata.

If the operation fails for any item and "Continue On Fail" is enabled, the output will include an error object with the error message for that particular item.

No binary data output is indicated.

Dependencies

  • Requires an OAuth2 API credential configured for Surense API access.
  • Dynamic options for properties like users, workflow types, and templates are loaded via internal methods calling Surense API endpoints.
  • No additional external dependencies beyond the Surense API and proper authentication.

Troubleshooting

  • Common Issues:

    • Invalid or missing required fields such as ownerId, assignedUserId, typeId, or customerId will cause errors.
    • Incorrect UUID formats for customerId or leadId may result in validation errors.
    • Authentication failures if the OAuth2 credential is not properly configured or expired.
    • Network or API downtime issues affecting communication with Surense API.
  • Error Messages:

    • Errors returned from the Surense API will be surfaced in the node output if "Continue On Fail" is enabled.
    • Typical messages might include "Invalid UUID format", "Unauthorized", or "Missing required parameter".
  • Resolutions:

    • Verify all required fields are correctly filled and formatted.
    • Ensure the OAuth2 credential is valid and has necessary permissions.
    • Check network connectivity and Surense API status.
    • Use expressions carefully to ensure they resolve to valid values.

Links and References

Discussion