Actions17
Overview
This node integrates with the Klaviyo API to retrieve detailed information about a specific Metric resource. The "Get One" operation fetches a single metric by its unique identifier, allowing users to obtain selected fields of the metric and optionally include related resources such as flow triggers. This is useful for scenarios where you need to analyze or display specific metrics from Klaviyo within an n8n workflow, for example, to monitor campaign performance or user engagement metrics.
Properties
| Name | Meaning |
|---|---|
| Metric ID | The unique identifier of the metric to retrieve. This is required to specify which metric to get. |
| Metric Fields | Select which fields of the metric to return. Options: name, created, updated, integration. |
| Additional Resources | Optionally include related resources in the response. Currently supports including flow-triggers. |
| Flow Fields | When including flow triggers, select which fields of the flow to return. Options: name, status, archived, created, updated, trigger_type. Requires "flow-triggers" to be selected in Additional Resources. |
Output
The output JSON contains the requested metric data with the specified fields. If additional resources like flow triggers are included, their data will also appear in the output under related keys. The structure follows the Klaviyo API's JSON:API format, typically including attributes such as metric name, creation and update timestamps, and integration details. No binary data is produced by this node.
Dependencies
- Requires an API key credential for authenticating with the Klaviyo API.
- The node sends requests to
https://a.klaviyo.com/apiwith appropriate headers for JSON:API content type. - Proper configuration of the API key credential in n8n is necessary.
Troubleshooting
- Missing or invalid Metric ID: Ensure that the Metric ID is provided and correctly formatted; otherwise, the API will return an error indicating the resource was not found.
- Insufficient permissions or invalid API key: Authentication errors may occur if the API key is missing, expired, or lacks access rights. Verify the API key credential setup.
- Invalid field selections: Selecting unsupported fields or combinations might result in incomplete data or API errors. Confirm that chosen fields are valid for the Metric and Flow resources.
- Including flow fields without selecting flow triggers: The node requires "flow-triggers" to be included in Additional Resources before flow fields can be requested. Omitting this may cause unexpected results or ignored parameters.