Actions5
- Campanha Actions
- Pessoa Actions
Overview
This node, named "CIS Assessment," interacts with a CIS Assessment API to perform various operations on different resources. Specifically, for the resource Campanha and operation Adquirir Campanha, it allows users to retrieve detailed information about a selected campaign by specifying its name or ID. This is useful in scenarios where you want to fetch campaign data dynamically within an automation workflow, such as reporting, monitoring campaign status, or integrating campaign details into other systems.
For example, you might use this node to:
- Automatically pull campaign details before sending notifications.
- Aggregate campaign data for analytics dashboards.
- Trigger follow-up actions based on campaign attributes.
Properties
| Name | Meaning |
|---|---|
| Campanha Name or ID | Select a campaign from a dropdown list or specify its ID using an expression. This identifies which campaign to acquire data for. |
The property supports loading options dynamically via the method getPassportOptions, allowing users to pick from existing campaigns easily.
Output
The node outputs a JSON array containing the data returned by the CIS Assessment API for the specified campaign. The structure of each JSON object corresponds to the campaign's details as provided by the API. This typically includes fields such as campaign identifiers, names, statuses, dates, and other relevant metadata.
If the node supports binary data output (not indicated explicitly here), it would represent associated files or attachments related to the campaign, but based on the code and properties, the output is primarily JSON data.
Dependencies
- Requires an active connection to the CIS Assessment API, authenticated via a required API key credential configured in n8n.
- Uses internal methods to load campaign options dynamically (
getPassportOptions). - Relies on the
resourceOperationFunctionsmapping to dispatch the correct function for the given resource-operation pair.
Troubleshooting
- Unsupported Operation Error: If you select a resource-operation combination not implemented, the node throws an error stating the operation is not supported. Ensure that the resource is set to "Campanha" and the operation to "Adquirir Campanha" or another supported pair.
- Empty or Invalid Campaign Selection: If no campaign is selected or an invalid ID is provided, the API call may fail or return empty results. Verify the campaign exists and is accessible.
- API Authentication Issues: Make sure the API key credential is correctly configured and has sufficient permissions to access campaign data.
- Dynamic Options Loading Fails: If the dropdown for campaigns does not populate, check network connectivity and API availability, as well as the correctness of the
getPassportOptionsmethod implementation.
Links and References
- n8n Expressions Documentation — For guidance on using expressions to specify dynamic values.
- CIS Assessment API documentation (refer to your API provider’s official docs for detailed endpoint and data schema information).