Actions76
- Data Export API Actions
- Metrics API Actions
- Get Page Activity Rate
- Get Page Bounce Rate
- Get Page Conversion Rate
- Get Page Exit Rate
- Get Page Fold Height
- Get Page Height
- Get Page Interaction Time
- Get Page Landing Rate
- Get Page Scroll Rate
- Get Page Time Spent
- Get Page Unique Visits
- Get Page Views
- Get Page Views per Visit
- Get Page Visits
- Get Page Web Vitals
- Get Site Bounce Rate
- Get Site Cart Average
- Get Site Conversion Rate
- Get Site Conversions
- Get Site Pageview Average
- Get Site Revenue
- Get Site Session Time Average
- Get Site Visits
- Get Zone Attractiveness Rate
- Get Zone Click Rate
- Get Zone Click Recurrence
- Get Zone Conversion Rate per Click
- Get Zone Conversion Rate per Hover
- Get Zone Conversion Rate per Tap
- Get Zone Engagement Rate
- Get Zone Exposure Rate
- Get Zone Exposure Time
- Get Zone Hesitation Time
- Get Zone Hover Rate
- Get Zone Hover Time
- Get Zone Number of Clicks
- Get Zone Revenue
- Get Zone Revenue per Click
- Get Zone Revenue per Tap
- Get Zone Swipe Rate
- Get Zone Swipe Rate Recurrence
- Get Zone Tap Rate
- Get Zone Tap Recurrence
- Get Zone Time Before First Click
- Get Zone Time Before First Tap
- List Goals
- List Mappings
- List Page Groups
- List Page Groups Metrics
- List Segments
- List Site Metrics
- List Zone Metrics
- List Zones
- List Zonings
- Speed Analysis API Actions
Overview
This node integrates with the Contentsquare API, enabling users to access various analytics and performance data related to user behavior on websites or apps. It supports three main API categories:
- Data Export API: Manage export jobs and retrieve export-related data.
- Metrics API: Fetch detailed metrics about user interactions, page performance, site statistics, zones (interactive areas), segments, goals, and more.
- Speed Analysis API: Create and manage speed analysis events, reports, and monitoring for web pages.
Typical use cases include automating the retrieval of user engagement metrics, exporting large datasets for offline analysis, monitoring website speed and performance, and integrating Contentsquare insights into broader workflows.
For example, a marketing analyst could use this node to automatically fetch daily page views and conversion rates, while a developer might automate speed monitoring reports to detect regressions in web performance.
Properties
Name | Meaning |
---|---|
Query Parameters | A collection of optional filters and parameters to customize the API request. Includes options such as: Device (All, Desktop, Mobile, Tablet), date ranges (startDate, endDate), format, frequency, goalId, limit, order, period, projectId, quantile, scope, segmentIds, state, etc. |
These parameters allow fine-tuning of the data retrieved from the API, such as filtering by device type, specifying date ranges, limiting results, and selecting metric types (Quantile or Average). |
Note: The full list of query parameters is extensive and includes fields like device
, endDate
, format
, frequency
, goalId
, ids
, limit
, metricType
, order
, page
, period
, projectId
, quantile
, scope
, segmentIds
, startDate
, state
, and to
.
Output
The node outputs JSON data representing the response from the Contentsquare API based on the selected resource and operation. The structure varies depending on the endpoint called but generally includes:
- Lists of metrics, jobs, runs, variables, goals, mappings, pages, zones, segments, or reports.
- Detailed metric values such as page activity rate, bounce rate, conversion rate, zone click rate, revenue, session times, and many others.
- Status codes or messages when no content is returned.
If the API returns a string response, the node attempts to parse it as JSON; otherwise, it outputs the raw text or a status message indicating no content.
The node does not output binary data.
Dependencies
- Requires an API authentication token obtained via OAuth 2.0 client credentials flow using:
- Client ID
- Client Secret
- Optional Project ID and Scope
- The node makes HTTP requests to the Contentsquare API endpoints.
- Users must configure appropriate credentials in n8n containing these authentication details.
Troubleshooting
- Missing Credentials: If the Client ID or Client Secret is missing, the node throws an error "Missing Client ID or Client Secret." Ensure credentials are correctly set up.
- Access Token Retrieval Failure: Errors like "Failed to retrieve access token" or "Failed to retrieve endpoint" indicate issues during OAuth token acquisition. Verify credentials and network connectivity.
- Required Parameter Missing: Many operations require specific IDs (e.g., Job ID, Page Group ID, Zone ID). If these are not provided, the node throws errors such as "Job ID is required" or "Zone ID is required." Provide all mandatory parameters.
- Unknown Resource: If an unsupported resource is specified, the node throws "Unknown resource" error.
- API Errors: Any API call failure will result in an error prefixed with "Error calling Contentsquare API," including the original message and stack trace if available.
- Empty or Unexpected Responses: If the API returns empty or non-JSON responses, the node handles them gracefully but verify that the API endpoint and parameters are correct.
Links and References
- Contentsquare API Documentation
- OAuth 2.0 Client Credentials Flow: https://oauth.net/2/grant-types/client-credentials/
- n8n HTTP Request Node Documentation: https://docs.n8n.io/nodes/n8n-nodes-base.httpRequest/
This summary covers the default resource and operation logic of the Contentsquare node as implemented in the provided source code and property definitions.