Connect Secure icon

Connect Secure

Consume Connect Secure API

Actions222

Overview

The "Ad Audit" node with the "Retrieve Event Stats" operation is designed to fetch event statistics data from an external API related to advertising audits. This node is useful for users who want to query and analyze event data such as user interactions, ad performance metrics, or audit logs filtered by specific conditions. It supports pagination, filtering, and ordering of results, making it suitable for scenarios like generating reports, monitoring ad campaigns, or auditing user events.

Practical examples:

  • Retrieve event stats for a specific user by providing their user ID.
  • Query event stats with custom conditions to filter by date range or event type.
  • Paginate through large datasets by skipping and limiting the number of records returned.
  • Order the results by a specific field such as timestamp or event count.

Properties

Name Meaning
X USER ID User Id (required). Used as a header value to identify the user for whom event stats are retrieved.
Condition Query Condition. A string to filter the event stats based on specific criteria.
Skip Skip Number of Records. An integer to skip a certain number of records in the result set (pagination).
Limit Limit. An integer to limit the number of records returned in the response.
Order By Order By. A string specifying the field(s) by which to order the returned event stats.

Output

The node outputs JSON data containing the retrieved event statistics matching the query parameters. The structure typically includes an array of event records with fields relevant to the ad audit context, such as event identifiers, timestamps, user IDs, and other metadata depending on the API's response schema.

If binary data were involved (not indicated here), it would represent files or media related to the events, but this node focuses on JSON event stats data only.

Dependencies

  • Requires an API key credential for authenticating requests to the Connect Secure API.
  • Depends on the external Connect Secure API service that provides the ad audit event statistics.
  • No additional environment variables or configurations are explicitly required beyond the API authentication setup.

Troubleshooting

  • Missing or invalid X USER ID: Since the user ID header is required, omitting it or providing an incorrect value will likely cause authentication or authorization errors. Ensure the correct user ID is provided.
  • Invalid query condition syntax: If the condition string is malformed or uses unsupported filters, the API may return errors or empty results. Validate the query condition format according to the API documentation.
  • Pagination issues: Setting skip or limit values incorrectly (e.g., negative numbers) might lead to unexpected results or errors.
  • Order By field not recognized: Using an invalid field name in the order_by parameter can cause the API to reject the request or ignore the ordering.
  • API connectivity problems: Network issues or invalid API credentials will prevent successful data retrieval. Verify API keys and network access.

Links and References

  • Refer to the Connect Secure API documentation for detailed information on query conditions, supported fields, and response formats.
  • n8n documentation on how to configure API credentials and use HTTP request nodes for similar integrations.

Discussion