Commanders Act icon

Commanders Act

Use the Commanders Act API

Actions108

Overview

This node integrates with the Commanders Act API, specifically allowing users to manage and interact with various resources within the Commanders Act platform. For the Web Container resource with the List Web Triggers operation, it fetches a list of web triggers configured in the user's Commanders Act environment.

This is useful for scenarios where you want to automate or monitor web triggers that are part of your tag management system, such as retrieving all triggers to analyze their configuration or to synchronize them with other systems.

Example use cases:

  • Automatically retrieve and log all web triggers for auditing purposes.
  • Use the list of web triggers to dynamically configure workflows based on trigger settings.
  • Integrate with other tools by exporting web trigger data regularly.

Properties

Name Meaning
Query Parameters A collection of optional query parameters to filter or modify the list request. These include:
- end (string)
- Fields[template] (string)
- filter (JSON)
- Various filter subfields like begin_date, end_date, from, rangeType, search, segment_id, sup_filters[device][], sup_filters[location][], to, types
- granularity (string)
- include (string)
- page (JSON)
- sort (JSON or string depending on context)
- source (string)
- start (string)
- token (string, password type)

The query parameters allow fine-tuning the API request, such as filtering results by date ranges, search terms, pagination, sorting, and other criteria supported by the Commanders Act API.

Output

The output is an array of JSON objects representing the web triggers retrieved from the Commanders Act API. Each object corresponds to a web trigger with its properties as returned by the API.

If the API returns binary data (not typical for this operation), it would be handled accordingly, but for listing web triggers, the output is purely JSON.

Example output structure (simplified):

[
  {
    "id": "trigger-id-1",
    "name": "Trigger Name 1",
    "type": "click",
    "conditions": [...],
    ...
  },
  {
    "id": "trigger-id-2",
    "name": "Trigger Name 2",
    "type": "pageview",
    "conditions": [...],
    ...
  }
]

Dependencies

  • Requires an active connection to the Commanders Act API.
  • Needs valid API credentials (an API token and site ID) configured in n8n.
  • The node uses the base URL https://api.commander1.com/v2.
  • No additional external dependencies beyond the API and credentials.

Troubleshooting

  • Missing Credentials Error: If the node throws an error about missing credentials, ensure that the Commanders Act API credentials are properly set up in n8n.
  • Required Parameter Missing: Some operations require specific IDs or parameters (e.g., containerId, triggerId). For the List Web Triggers operation, ensure that any required query parameters are correctly provided if needed.
  • API Errors: Errors returned from the API will be wrapped and shown with messages like "Error calling Commanders Act API". Check the API token validity, permissions, and network connectivity.
  • Empty Response: If no triggers are returned, verify that the account has web triggers configured and that any filters applied via query parameters are correct.

Links and References

Discussion